From aa602fcace337297b557ca4b856fa79f5ab29985 Mon Sep 17 00:00:00 2001 From: Flam3rboy <34555296+Flam3rboy@users.noreply.github.com> Date: Tue, 25 May 2021 01:11:16 +0200 Subject: [PATCH] npm i @fosscord/server-util@1.3.3 --- .env.example | 4 ++++ package-lock.json | Bin 133722 -> 133722 bytes package.json | 2 +- src/Server.ts | 3 ++- 4 files changed, 7 insertions(+), 2 deletions(-) create mode 100644 .env.example diff --git a/.env.example b/.env.example new file mode 100644 index 000000000..0224de64a --- /dev/null +++ b/.env.example @@ -0,0 +1,4 @@ +MONGO_URL=mongodb://localhost/fosscord +PORT=3002 +PRODUCTION=TRUE +THREADS=# automatically use all available cores, only available if production = true \ No newline at end of file diff --git a/package-lock.json b/package-lock.json index 6608281dedb190128f70b6a674bdc825817cced0..32c7f62c2a758549bd07408d114f91f18dd07926 100644 GIT binary patch delta 246 zcmcaLh2z!~jtRdQji<}YF)D19X4GPuesedY{`Au_j2e@jBoso^GF<}$EseANeIkNG z0-gNB%>tZELo&>wJUk5Zt9%0t^TJa@vQqMLi;RuZ%_A(F!o9L{U3??L)4WTAi~{^h z{fZ1y{k+^wvJ7*QGCT`Y(_9Ken*~|63$ieFOQ2d7Mia{%rz^TLN>4XXWn|ypEz5ZR F4FLUyP;USL delta 246 zcmcaLh2z!~jtRdQji$@XF)D19X4GPu{+XFcfBI<|Mvci#;R>Pt#YMT{E@2*39;qqr zzA1^t=Dr3-SpmN0l~n=S+P=m`IaRK~eqN3yrD=wi0eJ;xX6}W>hGl`4ImP;cUd6f2 z<~~)~mQ~4BuHnWJ0haFC{sslc&4Mi31z8xoB~UF3qlsmX(-mDArKcOHGO};)mSsHu F1^{n#PV@i( diff --git a/package.json b/package.json index 977927827..2d061bad1 100644 --- a/package.json +++ b/package.json @@ -13,7 +13,7 @@ "author": "Fosscord", "license": "ISC", "dependencies": { - "@fosscord/server-util": "^1.3.2", + "@fosscord/server-util": "^1.3.3", "ajv": "^8.5.0", "dotenv": "^8.2.0", "jsonwebtoken": "^8.5.1", diff --git a/src/Server.ts b/src/Server.ts index 46130b29a..2f72cc003 100644 --- a/src/Server.ts +++ b/src/Server.ts @@ -1,7 +1,7 @@ import "missing-native-js-functions"; import dotenv from "dotenv"; dotenv.config(); -import { db } from "@fosscord/server-util"; +import { Config, db } from "@fosscord/server-util"; import { Server as WebSocketServer } from "ws"; import { Connection } from "./events/Connection"; @@ -36,6 +36,7 @@ export class Server { // @ts-ignore await (db as Promise); await this.setupSchema(); + await Config.init(); console.log("[DB] connected"); console.log(`[Gateway] online on 0.0.0.0:${port}`); }