/*
godlighty -- highly-customizable HTTP, HTTP/2, HTTPS server
-Copyright (C) 2021 Sergey Matveev <stargrave@stargrave.org>
+Copyright (C) 2021-2023 Sergey Matveev <stargrave@stargrave.org>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
import (
"fmt"
"net/http"
+
+ "go.stargrave.org/godlighty"
)
func Redirect(
) {
http.Redirect(w, r, to, status)
fmt.Printf("%s %s \"%s %+q %s\" %d \"%s\"\n",
- r.RemoteAddr, host, r.Method, r.URL.Path, r.Proto,
+ r.RemoteAddr, host, r.Method, godlighty.PathWithQuery(r.URL), r.Proto,
status, r.Header.Get("User-Agent"),
)
}