mirror of
https://github.com/spacebarchat/server.git
synced 2024-11-11 05:02:37 +01:00
fix cdn
This commit is contained in:
parent
b68b1a1181
commit
0066ba223e
@ -1,5 +1,5 @@
|
|||||||
import { Server, ServerOptions } from "lambert-server";
|
import { Server, ServerOptions } from "lambert-server";
|
||||||
import { Config, db } from "@fosscord/util";
|
import { Config, initDatabase } from "@fosscord/util";
|
||||||
import path from "path";
|
import path from "path";
|
||||||
import avatarsRoute from "./routes/avatars";
|
import avatarsRoute from "./routes/avatars";
|
||||||
|
|
||||||
@ -13,8 +13,7 @@ export class CDNServer extends Server {
|
|||||||
}
|
}
|
||||||
|
|
||||||
async start() {
|
async start() {
|
||||||
// @ts-ignore
|
await initDatabase();
|
||||||
await (db as Promise<Connection>);
|
|
||||||
await Config.init();
|
await Config.init();
|
||||||
this.app.use((req, res, next) => {
|
this.app.use((req, res, next) => {
|
||||||
res.set("Access-Control-Allow-Origin", "*");
|
res.set("Access-Control-Allow-Origin", "*");
|
||||||
|
Loading…
Reference in New Issue
Block a user