@midwayjs/web 3.13.0 → 3.13.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/logger.js +5 -1
  2. package/package.json +2 -2
package/dist/logger.js CHANGED
@@ -84,7 +84,11 @@ class MidwayLoggers extends Map {
84
84
  configService.addObject(eggLoggerConfig);
85
85
  }
86
86
  }
87
- const loggerConfig = configService.getConfiguration('midwayLogger');
87
+ let loggerConfig = configService.getConfiguration('midwayLogger');
88
+ // 这里属于 hack 了,cluster 模式下会先走这里,找不到默认值
89
+ // 先合并一遍默认配置
90
+ configService.addObject(logger_1.loggers.getDefaultMidwayLoggerConfig(configService.getAppInfo()));
91
+ loggerConfig = configService.getConfiguration('midwayLogger');
88
92
  // 这里利用了 loggers 缓存的特性,提前初始化 logger
89
93
  if (loggerConfig) {
90
94
  for (const id of Object.keys(loggerConfig.clients)) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@midwayjs/web",
3
- "version": "3.13.0",
3
+ "version": "3.13.2",
4
4
  "description": "Midway Web Framework for Egg.js",
5
5
  "main": "dist/index.js",
6
6
  "typings": "index.d.ts",
@@ -60,5 +60,5 @@
60
60
  "engines": {
61
61
  "node": ">=12"
62
62
  },
63
- "gitHead": "9f55734afa5b08dcf46bc89493ec8edaa8c6202b"
63
+ "gitHead": "c9ebd3f575ca3f6756da33bcb53a477a9cfd3f71"
64
64
  }