diff --git a/lib/macro.ts b/lib/macro.ts index 0a44660..3d6d5af 100644 --- a/lib/macro.ts +++ b/lib/macro.ts @@ -30,7 +30,7 @@ const macroHandler: MacroHandler = (params) => { if (!somePath) { return; } - const programPath = somePath.findParent((path) => path.isProgram()); + const programPath = somePath.findParent((path) => path.isProgram())!; const registry = new RequirementRegistry(); const toReplace = [