fix: harden opencode project file probes

This commit is contained in:
Affaan Mustafa
2026-05-11 22:20:34 -04:00
committed by Affaan Mustafa
parent 629d4c0c61
commit 6d613f67dd
2 changed files with 47 additions and 1 deletions

View File

@@ -45,7 +45,7 @@ export const ECCHooksPlugin: ECCHooksPluginFn = async ({
function hasProjectFile(relativePath: string): boolean {
try {
return fs.existsSync(resolvePath(relativePath))
return fs.statSync(resolvePath(relativePath)).isFile()
} catch {
return false
}