diff --git a/apps/server/src/models/history.model.ts b/apps/server/src/models/history.model.ts index 857a0b6..015df87 100644 --- a/apps/server/src/models/history.model.ts +++ b/apps/server/src/models/history.model.ts @@ -67,7 +67,7 @@ export class GameHistoryRepository { if (k !== `game::${game_id}::${key}`) { const kTotal = parseInt((await this.redis.get(k)) || '0') if (kTotal < total - vote) { - this.redis.incrBy(k, Math.round(0.5 - (kTotal / (total + kTotal)) * vote)) + this.redis.incrBy(k, Math.round((0.5 - (kTotal / (total + kTotal))) * vote)) } } })