fix(fusion): prevent nested .fusion roots and safe fn version lookup

This commit is contained in:
gsxdsm
2026-05-03 02:02:25 -07:00
parent 41bb6be0f8
commit 8ba8f63163
14 changed files with 362 additions and 20 deletions

View File

@@ -25,6 +25,7 @@ import {
type RoutineManualTrigger,
MAX_ROUTINE_RUN_HISTORY,
} from "./routine.js";
import { assertProjectRootDir } from "./project-root-guard.js";
const CRON_TIMEZONE = "UTC";
@@ -71,6 +72,7 @@ export class RoutineStore extends EventEmitter<RoutineStoreEvents> {
constructor(private rootDir: string, options?: { inMemoryDb?: boolean }) {
super();
assertProjectRootDir(rootDir, "RoutineStore");
this.inMemoryDb = options?.inMemoryDb === true;
}