Skip to content

Commit 7429a01

Browse files
committed
Fix windows lint
1 parent 215374c commit 7429a01

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

modules/auth/sso/sspi_windows.go

+4-3
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ import (
1212
"code.gitea.io/gitea/models"
1313
"code.gitea.io/gitea/modules/base"
1414
"code.gitea.io/gitea/modules/log"
15+
"code.gitea.io/gitea/modules/middlewares"
1516
"code.gitea.io/gitea/modules/setting"
1617
"code.gitea.io/gitea/modules/templates"
1718

@@ -135,7 +136,7 @@ func (s *SSPI) VerifyAuthData(req *http.Request, w http.ResponseWriter, store Da
135136
}
136137

137138
// Make sure requests to API paths and PWA resources do not create a new session
138-
if !isAPIPath(req) && !isAttachmentDownload(req) {
139+
if !middlewares.IsAPIPath(req) && !isAttachmentDownload(req) {
139140
handleSignIn(w, req, sess, user)
140141
}
141142

@@ -166,9 +167,9 @@ func (s *SSPI) shouldAuthenticate(req *http.Request) (shouldAuth bool) {
166167
} else if req.FormValue("auth_with_sspi") == "1" {
167168
shouldAuth = true
168169
}
169-
} else if isInternalPath(req) {
170+
} else if middlewares.IsInternalPath(req) {
170171
shouldAuth = false
171-
} else if isAPIPath(req) || isAttachmentDownload(req) {
172+
} else if middlewares.IsAPIPath(req) || isAttachmentDownload(req) {
172173
shouldAuth = true
173174
}
174175
return

0 commit comments

Comments
 (0)