From 8505d9279b0855990619008b38094d17a0be2aeb Mon Sep 17 00:00:00 2001 From: Flam3rboy <34555296+Flam3rboy@users.noreply.github.com> Date: Tue, 2 Feb 2021 00:51:00 +0100 Subject: :art: Body Parser error --- src/test/mongo_test.ts | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'src/test/mongo_test.ts') diff --git a/src/test/mongo_test.ts b/src/test/mongo_test.ts index ad290198..d6906402 100644 --- a/src/test/mongo_test.ts +++ b/src/test/mongo_test.ts @@ -1,4 +1,6 @@ import mongoose from "mongoose"; +import { Long } from "mongodb"; +import { Snowflake } from "../util/Snowflake"; async function main() { const conn = await mongoose.createConnection( @@ -9,10 +11,7 @@ async function main() { } ); console.log("connected"); - const result = await conn - .collection("users") - .find({ $or: [{ email: "samuel.scheit@gmail.com" }, { phone: "samuel.scheit@gmail.com" }] }) - .toArray(); + const result = await conn.collection("users").insertOne({ test: Long.fromString(Snowflake.generate().toString()) }); // .project(undefined) console.log(result); -- cgit 1.5.1