hmem-mcp 6.1.1 → 6.1.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.
@@ -4141,7 +4141,9 @@ export function resolveHmemPath(cwdOverride) {
4141
4141
  // Priority 2: CWD discovery
4142
4142
  const cwd = cwdOverride || process.cwd();
4143
4143
  try {
4144
- const files = fs.readdirSync(cwd).filter(f => f.endsWith(".hmem"));
4144
+ const files = fs.readdirSync(cwd, { withFileTypes: true })
4145
+ .filter(e => e.isFile() && e.name.endsWith(".hmem"))
4146
+ .map(e => e.name);
4145
4147
  if (files.length === 1)
4146
4148
  return path.resolve(cwd, files[0]);
4147
4149
  if (files.length > 1) {