Browse Source

🐞 fix: 修复获取文件总结结果接口的bug

Pchen. 4 months ago
parent
commit
0530606a8a
1 changed files with 2 additions and 2 deletions
  1. 2 2
      apis/AI/GetFileSummary.js

+ 2 - 2
apis/AI/GetFileSummary.js

@@ -24,8 +24,8 @@ class GetFileSummary extends API {
                 ...BaseStdResponse.ACCESS_DENIED
             })
 
-        let sql = 'SELECT create_time, start_time, end_time, result, repo_hash FROM file_summary_tasks WHERE create_user = ? AND repo_id = ? AND repo_hash = ?'
-        let rows = await db.query(sql, [uuid, id, hash])
+        let sql = 'SELECT create_time, start_time, end_time, result, repo_hash FROM file_summary_tasks WHERE create_user = ? AND repo_id = ? AND repo_hash = ? AND filepath = ?'
+        let rows = await db.query(sql, [uuid, id, hash, filePath])
 
         if (!rows || rows.length === 0)
             return res.json({