Skip to content

Commit e728a03

Browse files
authored
Fix the opera log cost_time parameter (#95)
1 parent 465884e commit e728a03

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

backend/app/middleware/opera_log_middleware.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ async def __call__(self, scope: Scope, receive: Receive, send: Send) -> None:
9292
end_time = datetime.now()
9393
summary = request.scope.get('route').summary
9494
title = summary if summary != '' else request.scope.get('route').summary
95-
cost_time = (end_time - start_time).total_seconds() / 1000.0
95+
cost_time = (end_time - start_time).total_seconds() * 1000.0
9696

9797
# 日志创建
9898
opera_log_in = CreateOperaLog(

0 commit comments

Comments
 (0)