fix config fn unresolved name

This commit is contained in:
Jacob Nguyen
2024-05-26 14:03:32 -05:00
parent fc5e974f9b
commit 41046ebd37

View File

@@ -79,9 +79,7 @@ for await (const absPath of filePaths) {
commandModule = commandModule.default;
}
if (typeof config === 'function') {
config = config(absPath, commandModule);
}
try {
commandModule = commandModule.getInstance();
@@ -96,6 +94,9 @@ for await (const absPath of filePaths) {
commandModule.absPath = absPath;
modules.push({ commandModule, config });
}
if (typeof config === 'function') {
config = config(absPath, commandModule);
}
}
const cacheDir = resolve('./.sern');