summary refs log tree commit diff
path: root/src/Server.ts
diff options
context:
space:
mode:
authorFlam3rboy <34555296+Flam3rboy@users.noreply.github.com>2021-05-29 18:23:16 +0200
committerFlam3rboy <34555296+Flam3rboy@users.noreply.github.com>2021-05-29 18:23:16 +0200
commit3b032667851905eeec5c61d50be1e242e1aa739c (patch)
treef7fedb0feb073fe8abcdb4d2ced3428f16a2f666 /src/Server.ts
parent:sparkles: external assets (diff)
downloadserver-3b032667851905eeec5c61d50be1e242e1aa739c.tar.xz
:sparkles: avatars
Diffstat (limited to 'src/Server.ts')
-rw-r--r--src/Server.ts10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/Server.ts b/src/Server.ts

index de02a585..15868129 100644 --- a/src/Server.ts +++ b/src/Server.ts
@@ -1,6 +1,7 @@ import { Server, ServerOptions } from "lambert-server"; import { Config, db } from "@fosscord/server-util"; import path from "path"; +import multerConfig from "multer"; export interface CDNServerOptions extends ServerOptions {} @@ -26,3 +27,12 @@ export class CDNServer extends Server { return super.stop(); } } + +export const multer = multerConfig({ + storage: multerConfig.memoryStorage(), + limits: { + fields: 0, + files: 1, + fileSize: 1024 * 1024 * 100, // 100 mb + }, +});