@grwnd/pi-governance 3.0.1 → 3.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2981,8 +2981,9 @@ var piGovernance = (pi) => {
2981
2981
  }
2982
2982
  const rulesFileCfg = config.policy?.yaml?.rules_file ?? "./governance-rules.yaml";
2983
2983
  paths.add(resolve(rulesFileCfg));
2984
- paths.add(resolve(ctx.workingDirectory, ".pi/governance.yaml"));
2985
- paths.add(resolve(ctx.workingDirectory, "governance-rules.yaml"));
2984
+ const cwd = ctx.workingDirectory ?? process.cwd();
2985
+ paths.add(resolve(cwd, ".pi/governance.yaml"));
2986
+ paths.add(resolve(cwd, "governance-rules.yaml"));
2986
2987
  protectedPaths = paths;
2987
2988
  const chain = createIdentityChain(config.auth);
2988
2989
  identity = await chain.resolve();