From c0d2eac3329ec4454a178a4442bdcf20c388c8ff Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Fri, 14 Jan 2022 14:15:23 +0100 Subject: Update server dependencies --- server/lib/redis.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'server/lib/redis.ts') diff --git a/server/lib/redis.ts b/server/lib/redis.ts index 52766663a..f544274ea 100644 --- a/server/lib/redis.ts +++ b/server/lib/redis.ts @@ -365,8 +365,10 @@ class Redis { return this.client.incr(this.prefix + key) } - private exists (key: string) { - return this.client.exists(this.prefix + key) + private async exists (key: string) { + const result = await this.client.exists(this.prefix + key) + + return result !== 0 } private setExpiration (key: string, ms: number) { -- cgit v1.2.3