diff --git a/internal/utils/utils.go b/internal/utils/utils.go index d781fd7..c1f599c 100644 --- a/internal/utils/utils.go +++ b/internal/utils/utils.go @@ -85,10 +85,7 @@ func EnvSubst(input string) string { } func ReadUserIP(r *http.Request) string { - IPAddress := r.Header.Get("X-Real-Ip") - if IPAddress == "" { - IPAddress = r.Header.Get("X-Forwarded-For") - } + IPAddress := r.Header.Get("X-Forwarded-For") if IPAddress == "" { host, _, _ := net.SplitHostPort(r.RemoteAddr) IPAddress = host