Skip to content

Commit

Permalink
chore(zhi-core): basic load process
Browse files Browse the repository at this point in the history
  • Loading branch information
terwer committed Apr 15, 2023
1 parent f0f1a5a commit 47d2c0b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion apps/zhi-core/src/theme/core/lifecycle.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ import DependencyItem from "../models/DependencyItem"
* zhi主题统一生命周期管理
*
* @author terwer
* @since 1.0.0
* @since 0.1.0
*/
class Lifecycle {
public async load() {
Expand Down
6 changes: 3 additions & 3 deletions apps/zhi-core/src/theme/core/util/ZhiUtil.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
* questions.
*/

import LogFactory from "zhi-log"
import LogFactory, { DefaultLogger } from "zhi-log"
import Env from "zhi-env"

/**
Expand Down Expand Up @@ -68,7 +68,7 @@ class ZhiUtil {
/**
* 获取 zhi-log 实例
*/
public static zhiLog(loggerName: string) {
public static zhiLog(loggerName: string): DefaultLogger {
// 先检测日志Map
if (ZhiUtil.loggerMap) {
// 日志不存在,生成一个新的缓存到Map
Expand All @@ -88,7 +88,7 @@ class ZhiUtil {
}

// 从Map缓存获取日志器
return ZhiUtil.loggerMap[loggerName]
return ZhiUtil.loggerMap[loggerName] as DefaultLogger
}

// /**
Expand Down

0 comments on commit 47d2c0b

Please sign in to comment.