core: add server-loader (#816)

This commit is contained in:
undefined authored and GitHub committed 2024-06-03 19:29:41 +08:00
1 parent 3302480348
commit 97720efb65
57 files changed
+1328 -1131

No files matched your search

-5
View File
@@ -10,7 +10,6 @@ import yaml from 'js-yaml';
import { Context } from '../context';
import { Logger } from '../logger';
import { PRIV } from '../model/builtin';
import * as bus from '../service/bus';
import { unwrapExports } from '../utils';
const logger = new Logger('common');
@@ -55,7 +54,6 @@ const getLoader = (type: LoadTask, filename: string) => async function loader(pe
}
}
}
await bus.parallel(`app/load/${type}`);
};
export const handler = getLoader('handler', 'handler');
@@ -95,7 +93,6 @@ export async function locale(pending: string[], fail: string[]) {
}
}
}
await bus.parallel('app/load/locale');
}
export async function setting(pending: string[], fail: string[], modelSetting: typeof import('../model/setting')) {
@@ -137,7 +134,6 @@ export async function setting(pending: string[], fail: string[], modelSetting: t
}
}
}
await bus.parallel('app/load/setting');
}
export async function template(pending: string[], fail: string[]) {
@@ -161,5 +157,4 @@ export async function template(pending: string[], fail: string[]) {
}
}
}
await bus.parallel('app/load/template');
}