From f34ee18c301322ea02009efcc10ce86d350c68d0 Mon Sep 17 00:00:00 2001 From: marzavec Date: Thu, 7 Nov 2019 11:46:55 -0600 Subject: Minor bug fixes --- server/src/serverLib/RateLimiter.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'server/src/serverLib') diff --git a/server/src/serverLib/RateLimiter.js b/server/src/serverLib/RateLimiter.js index 3f9bc27..a4a0cd8 100644 --- a/server/src/serverLib/RateLimiter.js +++ b/server/src/serverLib/RateLimiter.js @@ -77,7 +77,7 @@ class RateLimiter { return true; } - record.score *= 2 ** -(Date.now() - record.time) / this.halflife; + record.score *= Math.pow(2, -(Date.now() - record.time ) / this.halflife); record.score += deltaScore; record.time = Date.now(); -- cgit v1.2.1