mirror of
https://github.com/flipped-aurora/gin-vue-admin.git
synced 2026-09-21 04:29:32 +00:00
fix(operation): 修复操作日志中间件,record.Resp写错的问题 (#1342)
This commit is contained in:
@@ -113,7 +113,7 @@ func OperationRecord() gin.HandlerFunc {
|
||||
// 截断
|
||||
newBody := respPool.Get().([]byte)
|
||||
copy(newBody, record.Resp)
|
||||
record.Body = string(newBody)
|
||||
record.Resp = string(newBody)
|
||||
defer respPool.Put(newBody[:0])
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user