From 773da154ff893687b4e679e875078919b377460c Mon Sep 17 00:00:00 2001 From: MrKBear Date: Wed, 1 Dec 2021 16:24:47 +0800 Subject: [PATCH] Optimize the output of Logger in AddModular --- miniprogram/core/Module.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/miniprogram/core/Module.ts b/miniprogram/core/Module.ts index 5d60c3a..802563f 100644 --- a/miniprogram/core/Module.ts +++ b/miniprogram/core/Module.ts @@ -425,9 +425,9 @@ class Manager { func.push(`[${ key }]`); } - let log:string = `模块 [${ this.modules[i].nameSpace }] 加载:\n`; - log += `Using Props: ${ data.join(", ") }\n`; - log += `Using Function: ${ func.join(", ") }\n`; + let log:string = `模块 [${ this.modules[i].nameSpace }] 加载完成...\n`; + if(data.length > 0) log += `Using Props: ${ data.join(", ") }\n`; + if(func.length > 0) log += `Using Function: ${ func.join(", ") }\n`; Logger.log(log, LevelLogLabel.TraceLabel, Manager.AddModuleLabel); }