diff --git a/src/config.ts b/src/config.ts index 28b687e..a58f68a 100644 --- a/src/config.ts +++ b/src/config.ts @@ -1,3 +1,4 @@ +import consola from 'consola'; import { config as configDotenv } from 'dotenv'; import { CountryCode } from 'libphonenumber-js'; import ValidatorJS from 'validator'; @@ -20,12 +21,15 @@ export const config = { } let errors = 0 if (typeof config.internal_port !== "number") { + consola.error("Error: APP_PORT is not a number") errors++ } if (typeof config.development !== "boolean") { + consola.error("Error: NODE_ENV is not a boolean") errors++ } if (config.mailer_url == "" || config.mailer_key == "") { + consola.error("Error: invalid mailer config") errors++; } function getPhoneCodeLocale(): CountryCode {