@probelabs/probe-chat 0.6.0-rc103 → 0.6.0-rc104
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.
- package/package.json +1 -1
- package/probeTool.js +5 -9
package/package.json
CHANGED
package/probeTool.js
CHANGED
|
@@ -534,15 +534,11 @@ const baseSearchFilesTool = {
|
|
|
534
534
|
await fsPromises.access(searchDir);
|
|
535
535
|
} catch (err) {
|
|
536
536
|
console.error(`Directory does not exist: ${searchDir}`);
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
files: [],
|
|
543
|
-
count: 0,
|
|
544
|
-
timestamp: new Date().toISOString()
|
|
545
|
-
};
|
|
537
|
+
console.error(`Falling back to search in parent directory: ${targetDir}`);
|
|
538
|
+
// Fall back to searching in the parent directory instead of failing
|
|
539
|
+
searchDir = targetDir;
|
|
540
|
+
// Adjust the pattern to include the subdirectory in the search
|
|
541
|
+
filePattern = pattern; // Use the original pattern for glob matching
|
|
546
542
|
}
|
|
547
543
|
|
|
548
544
|
// Read directory contents
|