zhi-2026-04-18 #1

Merged
hzhang merged 5 commits from zhi-2026-04-18 into main 2026-05-01 07:21:25 +00:00
Showing only changes of commit bee3dcb84c - Show all commits

View File

@@ -38,8 +38,8 @@ export default {
register(api: OpenClawPluginApi) {
const config = normalizeConfig(api);
const pluginDir = path.dirname(new URL(import.meta.url).pathname);
const routersDir = config.routersDir || path.resolve(pluginDir, "..", "routers");
const rulesFile = config.rulesFile || path.resolve(pluginDir, "..", "rules.json");
const routersDir = config.routersDir || path.resolve(pluginDir, "routers");
const rulesFile = config.rulesFile || path.resolve(pluginDir, "rules.json");
// Gateway lifecycle: init once
if (!_G[LIFECYCLE_KEY]) {