mirror of
https://github.com/Unleash/unleash.git
synced 2025-10-27 11:02:16 +01:00
Use coalesce instead of if
This commit is contained in:
parent
a0ac6502fa
commit
9cb27364a0
@ -787,9 +787,8 @@ export function createConfig(options: IUnleashOptions): IUnleashConfig {
|
||||
process.env.PROMETHEUS_IMPACT_METRICS_API;
|
||||
|
||||
const checkDbOnReady =
|
||||
typeof options.checkDbOnReady === 'boolean'
|
||||
? options.checkDbOnReady
|
||||
: parseEnvVarBoolean(process.env.CHECK_DB_ON_READY, false);
|
||||
Boolean(options.checkDbOnReady) ??
|
||||
parseEnvVarBoolean(process.env.CHECK_DB_ON_READY, false);
|
||||
|
||||
return {
|
||||
db,
|
||||
|
||||
Loading…
Reference in New Issue
Block a user