Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion api/get_ip.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ func GetIP(w http.ResponseWriter, r *http.Request, _ httprouter.Params) {
// list. We do this because this is always the *origin* IP address, which
// is the *true* IP of the user. For more information on this, see the
// Wikipedia page: https://en.wikipedia.org/wiki/X-Forwarded-For
ip := net.ParseIP(strings.Split(r.Header.Get("X-Forwarded-For"), ",")[0]).String()
ip := net.ParseIP(strings.Split(r.Header.Get("X-Forwarded-For"), ", ")[0]).String()

// If the user specifies a 'format' querystring, we'll try to return the
// user's IP address in the specified format.
Expand Down