mirror of
https://github.com/mollersuite/monofile.git
synced 2024-11-24 22:56:26 -08:00
add some stuff
This commit is contained in:
parent
364c3627a4
commit
e4a4e24d6c
|
@ -15,6 +15,7 @@ export interface Configuration {
|
|||
requiredForUpload: boolean
|
||||
}
|
||||
mail: {
|
||||
enabled: boolean
|
||||
transport: {
|
||||
host: string
|
||||
port: number
|
||||
|
@ -31,6 +32,8 @@ export interface Configuration {
|
|||
export interface ClientConfiguration {
|
||||
version: string
|
||||
files: number
|
||||
totalSize: number
|
||||
mailEnabled: boolean
|
||||
maxDiscordFiles: number
|
||||
maxDiscordFileSize: number
|
||||
accounts: {
|
||||
|
@ -56,6 +59,8 @@ export default {
|
|||
},
|
||||
|
||||
mail: {
|
||||
enabled: ["HOST","PORT","SEND_FROM","USER","PASS"].every(e => Boolean(process.env[`MAIL__${e}`])),
|
||||
|
||||
transport: {
|
||||
host: process.env.MAIL__HOST,
|
||||
port: Number(process.env.MAIL__PORT),
|
||||
|
|
|
@ -21,7 +21,8 @@ export default function(files: Files) {
|
|||
totalSize: Object.values(files.files).filter(e => e.sizeInBytes).reduce((acc,cur)=>acc+cur.sizeInBytes!,0),
|
||||
maxDiscordFiles: config.maxDiscordFiles,
|
||||
maxDiscordFileSize: config.maxDiscordFileSize,
|
||||
accounts: config.accounts
|
||||
accounts: config.accounts,
|
||||
mailEnabled: config.mail.enabled
|
||||
} as ClientConfiguration)
|
||||
)
|
||||
|
||||
|
|
Loading…
Reference in a new issue