From 514afaca697ae5f9a02e91342c0434fe9eeffe74 Mon Sep 17 00:00:00 2001 From: Flam3rboy <34555296+Flam3rboy@users.noreply.github.com> Date: Thu, 4 Mar 2021 21:59:49 +0100 Subject: :sparkles: AuditLog --- src/util/MongoBigInt.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/util/MongoBigInt.ts') diff --git a/src/util/MongoBigInt.ts b/src/util/MongoBigInt.ts index 28818212..c4e5f623 100644 --- a/src/util/MongoBigInt.ts +++ b/src/util/MongoBigInt.ts @@ -33,7 +33,7 @@ class LongSchema extends mongoose.SchemaType { cast(val: any, scope?: any, init?: any, type?: string) { if (null === val) return val; if ("" === val) return null; - if (typeof val === "bigint" && type === "query") { + if (typeof val === "bigint") { return mongoose.mongo.Long.fromString(val.toString()); } -- cgit 1.5.1