aboutsummaryrefslogtreecommitdiff
path: root/internal/headers.go
diff options
context:
space:
mode:
authorXe Iaso <me@xeiaso.net>2025-03-29 15:00:22 -0400
committerGitHub <noreply@github.com>2025-03-29 15:00:22 -0400
commit52ca5390c2b54374e62cbcd2efaf78edaa4e7249 (patch)
treee40c639e99e501bdb91acdc1750d7d16e36cc655 /internal/headers.go
parent6b2ae30baef6cdc1796a5ec5495c11686aaca50e (diff)
downloadanubis-52ca5390c2b54374e62cbcd2efaf78edaa4e7249.tar.xz
anubis-52ca5390c2b54374e62cbcd2efaf78edaa4e7249.zip
Add staticheck to CI (#152)
* Add staticheck to CI Signed-off-by: Xe Iaso <me@xeiaso.net> * fix staticcheck warnings Signed-off-by: Xe Iaso <me@xeiaso.net> * oh, right, playwright is broken Signed-off-by: Xe Iaso <me@xeiaso.net> --------- Signed-off-by: Xe Iaso <me@xeiaso.net>
Diffstat (limited to 'internal/headers.go')
-rw-r--r--internal/headers.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/internal/headers.go b/internal/headers.go
index d73fa33..a48ce54 100644
--- a/internal/headers.go
+++ b/internal/headers.go
@@ -26,7 +26,7 @@ func UnchangingCache(next http.Handler) http.Handler {
// RemoteXRealIP sets the X-Real-Ip header to the request's real IP if
// the setting is enabled by the user.
func RemoteXRealIP(useRemoteAddress bool, bindNetwork string, next http.Handler) http.Handler {
- if useRemoteAddress == false {
+ if !useRemoteAddress {
slog.Debug("skipping middleware, useRemoteAddress is empty")
return next
}