From 81dd17869116f70db375597b59232fa8cb11a868 Mon Sep 17 00:00:00 2001 From: Benjamin Auder <benjamin.auder@somewhere> Date: Thu, 8 Apr 2021 22:20:23 +0200 Subject: [PATCH] Adjustments --- client/src/components/ChallengeList.vue | 4 ++-- client/src/views/Hall.vue | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/client/src/components/ChallengeList.vue b/client/src/components/ChallengeList.vue index cf4565ad..7316c266 100644 --- a/client/src/components/ChallengeList.vue +++ b/client/src/components/ChallengeList.vue @@ -48,7 +48,7 @@ export default { } if (c.added < minAdded) minAdded = c.added; if (c.added > maxAdded) maxAdded = c.added; - return Object.assign({}, c, { priority: priority }); + return Object.assign({ priority: priority }, c); }); const deltaAdded = maxAdded - minAdded; return augmentedChalls.sort((c1, c2) => { @@ -63,7 +63,7 @@ export default { return c.from.name || "@nonymous"; }, getRandomnessClass: function(c) { - if (!c.options.randomness) return {}; + if (!Number.isInteger(c.options.randomness)) return {}; return { ["random-" + c.options.randomness]: true }; diff --git a/client/src/views/Hall.vue b/client/src/views/Hall.vue index c9a15eaa..091c7154 100644 --- a/client/src/views/Hall.vue +++ b/client/src/views/Hall.vue @@ -479,7 +479,7 @@ export default { this.conn = null; }, getRandomnessClass: function(pc) { - if (!pc.options.randomness) return {}; + if (!Number.isInteger(pc.options.randomness)) return {}; return { ["random-" + pc.options.randomness]: true }; -- 2.44.0