Skip to content

Commit

Permalink
Strip any port if present
Browse files Browse the repository at this point in the history
  • Loading branch information
ErikPelli committed Dec 30, 2024
1 parent 020a007 commit c63debf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion dispatcher.go
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ func UrlMatches(re *regexp.Regexp) ReqConditionFunc {
func DstHostIs(host string) ReqConditionFunc {
host = strings.ToLower(host)
return func(req *http.Request, ctx *ProxyCtx) bool {
return strings.ToLower(req.URL.Host) == host
return strings.ToLower(req.URL.Hostname()) == host
}
}

Expand Down

0 comments on commit c63debf

Please sign in to comment.