Fix remote IP, fix title

This commit is contained in:
blankhex committed 2026-10-21 20:28:50 +03:00
1 parent 284e4e7080
commit b5630d2af7
6 files changed
+39 -14

No files matched your search

-9
View File
@@ -2,7 +2,6 @@ package rest
import (
"fmt"
"net"
"net/http"
"goAuth/internal/auth"
@@ -27,14 +26,6 @@ func sessionFromRequest(r *http.Request) *auth.Session {
return session
}
func clientAddress(r *http.Request) string {
host, _, err := net.SplitHostPort(r.RemoteAddr)
if err != nil {
return r.RemoteAddr
}
return host
}
func formatUserId(id int64) string {
return fmt.Sprintf("user-%d", id)
}