@ian2018cs/agenthub 0.1.100 → 0.2.0
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/server/routes/agents.js +14 -2
package/package.json
CHANGED
package/server/routes/agents.js
CHANGED
|
@@ -1268,9 +1268,21 @@ router.post('/generate-description', async (req, res) => {
|
|
|
1268
1268
|
|
|
1269
1269
|
const config = await loadProjectConfig(userUuid);
|
|
1270
1270
|
const entry = config[projectKey];
|
|
1271
|
-
if (!entry) return res.status(404).json({ error: 'Project not found' });
|
|
1272
1271
|
|
|
1273
|
-
|
|
1272
|
+
let projectPath;
|
|
1273
|
+
if (entry?.originalPath) {
|
|
1274
|
+
projectPath = entry.originalPath;
|
|
1275
|
+
} else if (entry) {
|
|
1276
|
+
projectPath = projectKey.replace(/-/g, '/');
|
|
1277
|
+
} else {
|
|
1278
|
+
// Project may be a CLI-scanned project with different key encoding (e.g. _ → -) not in manual config
|
|
1279
|
+
try {
|
|
1280
|
+
projectPath = await extractProjectDirectory(projectKey, userUuid);
|
|
1281
|
+
if (!projectPath) return res.status(404).json({ error: 'Project not found' });
|
|
1282
|
+
} catch {
|
|
1283
|
+
return res.status(404).json({ error: 'Project not found' });
|
|
1284
|
+
}
|
|
1285
|
+
}
|
|
1274
1286
|
|
|
1275
1287
|
// Read CLAUDE.md if available
|
|
1276
1288
|
let claudeMdContent = '';
|