small pixel drawing of a pufferfish vore

add TrimSpace to parseDomain
Jes Olson j3s@c3f.net
Mon, 20 Mar 2023 21:56:44 -0700
commit

834e8b4b94f692a1dee867a549be5d935fec6979

parent

3a640a8f4f60de59e17964dcc4d3528e8a493546

1 files changed, 2 insertions(+), 1 deletions(-)

jump to
M site.gosite.go

@@ -311,7 +311,8 @@ if err == nil {

return parsedURL.Hostname() } // do our best to trim it manually if url parsing fails - trimmedStr := strings.TrimPrefix(rawURL, "http://") + trimmedStr := strings.TrimSpace(rawURL) + trimmedStr = strings.TrimPrefix(rawURL, "http://") trimmedStr = strings.TrimPrefix(trimmedStr, "https://") return strings.Split(trimmedStr, "/")[0]