mirror of
https://github.com/spacebarchat/server.git
synced 2024-11-11 13:14:06 +01:00
🐛 make server options optional
This commit is contained in:
parent
5856047e3d
commit
532d7b16a1
14
package-lock.json
generated
14
package-lock.json
generated
@ -9,7 +9,7 @@
|
||||
"version": "1.0.0",
|
||||
"license": "ISC",
|
||||
"dependencies": {
|
||||
"@fosscord/server-util": "^1.3.14",
|
||||
"@fosscord/server-util": "^1.3.16",
|
||||
"ajv": "^8.5.0",
|
||||
"dotenv": "^8.2.0",
|
||||
"jsonwebtoken": "^8.5.1",
|
||||
@ -31,9 +31,9 @@
|
||||
}
|
||||
},
|
||||
"node_modules/@fosscord/server-util": {
|
||||
"version": "1.3.14",
|
||||
"resolved": "https://registry.npmjs.org/@fosscord/server-util/-/server-util-1.3.14.tgz",
|
||||
"integrity": "sha512-P9qQ8bc01SjhRFFjw1WF3Q4rpwb4Sn8fDwwO+jeodAzhGFD1PjhBkG2xAO1UbA8LkF8+cJ8NgLFBUGzNXJTZJQ==",
|
||||
"version": "1.3.16",
|
||||
"resolved": "https://registry.npmjs.org/@fosscord/server-util/-/server-util-1.3.16.tgz",
|
||||
"integrity": "sha512-/oDDGyWllVNMb/84wzzYQ6vpwkcW+mg57ECWS5bUDQ0OhT3apdpYgQFfWxwGYgyYo6fB4gmyJh/U2bzWo6Jmeg==",
|
||||
"dependencies": {
|
||||
"@types/jsonwebtoken": "^8.5.0",
|
||||
"@types/mongoose-autopopulate": "^0.10.1",
|
||||
@ -2084,9 +2084,9 @@
|
||||
},
|
||||
"dependencies": {
|
||||
"@fosscord/server-util": {
|
||||
"version": "1.3.14",
|
||||
"resolved": "https://registry.npmjs.org/@fosscord/server-util/-/server-util-1.3.14.tgz",
|
||||
"integrity": "sha512-P9qQ8bc01SjhRFFjw1WF3Q4rpwb4Sn8fDwwO+jeodAzhGFD1PjhBkG2xAO1UbA8LkF8+cJ8NgLFBUGzNXJTZJQ==",
|
||||
"version": "1.3.16",
|
||||
"resolved": "https://registry.npmjs.org/@fosscord/server-util/-/server-util-1.3.16.tgz",
|
||||
"integrity": "sha512-/oDDGyWllVNMb/84wzzYQ6vpwkcW+mg57ECWS5bUDQ0OhT3apdpYgQFfWxwGYgyYo6fB4gmyJh/U2bzWo6Jmeg==",
|
||||
"requires": {
|
||||
"@types/jsonwebtoken": "^8.5.0",
|
||||
"@types/mongoose-autopopulate": "^0.10.1",
|
||||
|
@ -13,7 +13,7 @@
|
||||
"author": "Fosscord",
|
||||
"license": "ISC",
|
||||
"dependencies": {
|
||||
"@fosscord/server-util": "^1.3.14",
|
||||
"@fosscord/server-util": "^1.3.16",
|
||||
"ajv": "^8.5.0",
|
||||
"dotenv": "^8.2.0",
|
||||
"jsonwebtoken": "^8.5.1",
|
||||
|
@ -11,7 +11,7 @@ export class Server {
|
||||
public port: number;
|
||||
public server: http.Server;
|
||||
|
||||
constructor({ port, server }: { port: number; server: http.Server }) {
|
||||
constructor({ port, server }: { port: number; server?: http.Server }) {
|
||||
this.port = port;
|
||||
if (server) this.server = server;
|
||||
else this.server = http.createServer({});
|
||||
|
Loading…
Reference in New Issue
Block a user