X-Git-Url: https://git.auder.net/?p=vchess.git;a=blobdiff_plain;f=client%2Fsrc%2Fcomponents%2FChallengeList.vue;h=21179a656899936904ab175fe48d464a6f416821;hp=7316c266a01d4ecdae463bd46447378ccefaadd3;hb=2eca7311a1f02285ec875be35cf73b32bdd3b73c;hpb=81dd17869116f70db375597b59232fa8cb11a868 diff --git a/client/src/components/ChallengeList.vue b/client/src/components/ChallengeList.vue index 7316c266..21179a65 100644 --- a/client/src/components/ChallengeList.vue +++ b/client/src/components/ChallengeList.vue @@ -63,7 +63,13 @@ export default { return c.from.name || "@nonymous"; }, getRandomnessClass: function(c) { - if (!Number.isInteger(c.options.randomness)) return {}; + if ( + // TODO: one extra test here + !Number.isInteger(c.options.randomness) && + !parseInt(c.options.randomness, 10) + ) { + return {}; + } return { ["random-" + c.options.randomness]: true };