summary refs log tree commit diff
path: root/src/Server.ts
diff options
context:
space:
mode:
authorFlam3rboy <34555296+Flam3rboy@users.noreply.github.com>2021-04-26 00:12:27 +0200
committerGitHub <noreply@github.com>2021-04-26 00:12:27 +0200
commit40e86e43a40a1b64eedeb2a2e5238bf6c1bb7afd (patch)
tree9f2883ce00b27e5ee431529f6d8a0ce4965f17a8 /src/Server.ts
parent:bug: fix dev script (diff)
parentMerge branch 'master' of https://github.com/aryan0078/fosscord-api (diff)
downloadserver-40e86e43a40a1b64eedeb2a2e5238bf6c1bb7afd.tar.xz
Merge pull request #86 from aryan0078/master
Channel Delete + Modify Route
Diffstat (limited to 'src/Server.ts')
-rw-r--r--src/Server.ts7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/Server.ts b/src/Server.ts

index c7c52c1f..c7f36233 100644 --- a/src/Server.ts +++ b/src/Server.ts
@@ -12,8 +12,13 @@ import { ErrorHandler } from "./middlewares/ErrorHandler"; import { BodyParser } from "./middlewares/BodyParser"; import { Router } from "express"; import fetch from "node-fetch"; +import mongoose from "mongoose"; -export interface FosscordServerOptions extends ServerOptions {} +// this will return the new updated document for findOneAndUpdate +mongoose.set('returnOriginal', false); // https://mongoosejs.com/docs/api/model.html#model_Model.findOneAndUpdate + + +export interface FosscordServerOptions extends ServerOptions { } declare global { namespace Express {