Fix AddProjectModal to use isDirectory property for directory checks

Updated the directory check in AddProjectModal to use the isDirectory property instead of type for better clarity and consistency in identifying the '.auto-claude' folder. This change enhances the reliability of the existing functionality that checks for the presence of the specified directory.
This commit is contained in:
AndyMik90
2026-01-27 07:06:42 +01:00
parent 9fcf21a725
commit 5fadec1fce
@@ -103,7 +103,7 @@ export function AddProjectModal({ open, onOpenChange, onProjectAdded }: AddProje
const listResult = await window.electronAPI.listDirectory(path);
if (listResult.success && listResult.data) {
const hasAutoClaudeFolder = listResult.data.some(
(item) => item.name === '.auto-claude' && item.type === 'directory'
(item) => item.name === '.auto-claude' && item.isDirectory
);
setExistingHasAutoClaude(hasAutoClaudeFolder);
} else {