perf: delete settings.ts use serverConfig.json

This commit is contained in:
xiaoxian521
2021-10-15 11:38:43 +08:00
parent cafc588e4c
commit e22e19552a
9 changed files with 46 additions and 35 deletions

View File

@@ -6,7 +6,7 @@ const setConfig = (cfg?: unknown) => {
config = Object.assign(config, cfg);
};
const getConfig = (key?: string) => {
const getConfig = (key?: string): ServerConfigs => {
if (typeof key === "string") {
const arr = key.split(".");
if (arr && arr.length) {