Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit28a11a6

Browse files
committed
linting fixes
1 parent4400dd5 commit28a11a6

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

‎coderd/httpmw/logger.go

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,7 @@ func Logger(log slog.Logger) func(next http.Handler) http.Handler {
5757
// We already capture most of this information in the span (minus
5858
// the response body which we don't want to capture anyways).
5959
tracing.RunWithoutSpan(r.Context(),func(ctx context.Context) {
60-
// logLevelFn(ctx, r.Method)
61-
logContext.WriteLog(r.Context(),sw.Status)
60+
logContext.WriteLog(ctx,sw.Status)
6261
})
6362
})
6463
}
@@ -100,9 +99,9 @@ func (c *RequestLoggerContext) WriteLog(ctx context.Context, status int) {
10099
// includes proxy errors etc. It also causes slogtest to fail
101100
// instantly without an error message by default.
102101
ifstatus>=http.StatusInternalServerError {
103-
c.log.Error(ctx,c.message,"status_code",status)
102+
c.log.Error(ctx,c.message)
104103
}else {
105-
c.log.Debug(ctx,c.message,"status_code",status)
104+
c.log.Debug(ctx,c.message)
106105
}
107106
}
108107

File renamed without changes.

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp