Skip to content

Commit a1c3764

Browse files
authored
refactor(gin): improve log message (#901)
* refactor(gin): simplify xid check and improve error message * imporve log * adjust the code * update
1 parent a1816a9 commit a1c3764

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pkg/integration/gin/gin_transaction_middleware.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ func TransactionMiddleware() gin.HandlerFunc {
3737
}
3838

3939
if len(xid) == 0 {
40-
log.Errorf("Gin: header not contain header: %s, global transaction xid", constant.XidKey)
40+
log.Errorf("Gin: header does not contain: %s or %s, global transaction xid is missing", constant.XidKey, constant.XidKeyLowercase)
4141
ctx.AbortWithStatus(http.StatusBadRequest)
4242
return
4343
}

0 commit comments

Comments
 (0)