mirror of
https://github.com/go-gitea/gitea.git
synced 2026-10-08 18:33:00 +02:00
Improve log format (#33814)
This commit is contained in:
1 parent
6422f05a4e
commit
4ed71eb754
13 files changed
+120
-74
No files matched your search
@@ -92,7 +92,7 @@ func (lr *accessLogRecorder) record(start time.Time, respWriter ResponseWriter,
|
||||
log.Error("Could not execute access logger template: %v", err.Error())
|
||||
}
|
||||
|
||||
lr.logger.Log(1, log.INFO, "%s", buf.String())
|
||||
lr.logger.Log(1, &log.Event{Level: log.INFO}, "%s", buf.String())
|
||||
}
|
||||
|
||||
func newAccessLogRecorder() *accessLogRecorder {
|
||||
|
||||
@@ -20,7 +20,7 @@ type testAccessLoggerMock struct {
|
||||
logs []string
|
||||
}
|
||||
|
||||
func (t *testAccessLoggerMock) Log(skip int, level log.Level, format string, v ...any) {
|
||||
func (t *testAccessLoggerMock) Log(skip int, event *log.Event, format string, v ...any) {
|
||||
t.logs = append(t.logs, fmt.Sprintf(format, v...))
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user