Browse Source

修复格式问题

fulian23 4 months ago
parent
commit
a4e0c76782
1 changed files with 2 additions and 2 deletions
  1. 2 2
      api/aiRouter.py

+ 2 - 2
api/aiRouter.py

@@ -187,7 +187,7 @@ async def commit_task(content,repo_id):
         print(f"提交出错: {commit_result}")
     else:
         print("提交成功")
-        await Commit_Summary_Tasks.filter(repo_id=repo_id).update(result=commit_result,end_time=int(time.time()))
+        await Commit_Summary_Tasks.filter(repo_id=repo_id).update(result=commit_result[0],end_time=int(time.time()))
 
 async def file_task(file_path,repo_id):
     with open(file_path, 'r', encoding="utf8") as f:
@@ -197,7 +197,7 @@ async def file_task(file_path,repo_id):
         print(f"提交出错: {file_result}")
     else:
         print("提交成功")
-        await File_Summary_Tasks.filter(repo_id=repo_id).update(result=file_result, end_time=int(time.time()))
+        await File_Summary_Tasks.filter(repo_id=repo_id).update(result=file_result[0], end_time=int(time.time()))