From 4fd96daaf5af4ac122b9d8ada8de52fa9323ca56 Mon Sep 17 00:00:00 2001 From: godakid Date: Sun, 8 Sep 2024 13:08:03 +0800 Subject: [PATCH] fix: parse undefined --- index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.ts b/index.ts index 4d9493c..40a386f 100644 --- a/index.ts +++ b/index.ts @@ -53,7 +53,7 @@ const parsedConfig = yaml.parse(await safeRun(() => { // S 相关配置 const choice = (cmd: any, parsed: any, defaultConfig: any) => { return cmd ?? - _.isNull(parsed) ? + (_.isUndefined(parsed) || _.isNull(parsed)) ? defaultConfig : parsed; };