diff options
Diffstat (limited to 'gopher/request.go')
-rw-r--r-- | gopher/request.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gopher/request.go b/gopher/request.go index 6c708c0..ef68438 100644 --- a/gopher/request.go +++ b/gopher/request.go @@ -25,10 +25,10 @@ func ParseRequest(rdr io.Reader) (*gus.Request, error) { return &gus.Request{ URL: &url.URL{ Scheme: "gopher", - Path: path.Clean(strings.TrimRight(selector, "\r\n")), + Path: path.Clean(strings.TrimSuffix(selector, "\r\n")), OmitHost: true, //nolint:typecheck // (for some reason typecheck on drone-ci doesn't realize OmitHost is a field in url.URL) - RawQuery: url.QueryEscape(strings.TrimRight(search, "\r\n")), + RawQuery: url.QueryEscape(strings.TrimSuffix(search, "\r\n")), }, }, nil } |