Skip to content

Commit

Permalink
[main] normalize scriptsDir in config
Browse files Browse the repository at this point in the history
  • Loading branch information
dubdia committed Nov 6, 2024
1 parent 5a7f979 commit 7e2cee0
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions src/main/config/app-config-manager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,17 @@ export class AppConfigManager extends ConfigManager<AppConfig> {
return new AppConfig();
}
protected normalize(config: AppConfig): void {
if (config.logLevel == null || (config.logLevel?.toString()) == "") {
if (config.logLevel == null || config.logLevel?.toString() == "") {
config.logLevel = "info";
}
if (config.devTools == null || (config.devTools?.toString()) == "") {
if (config.devTools == null || config.devTools?.toString() == "") {
config.devTools = false;
}
if (config.logSsh == null || (config.logSsh?.toString()) == "") {
if (config.logSsh == null || config.logSsh?.toString() == "") {
config.logSsh = false;
}
if (config.scriptsDir == null) {
config.scriptsDir = "";
}
}
}

0 comments on commit 7e2cee0

Please sign in to comment.