fix: relax chunk limits, support proxies, optimize reads

Signed-off-by: skidoodle <contact@albert.lol>
This commit is contained in:
2026-01-19 00:33:09 +01:00
parent 722dbaa6aa
commit 2df37e9002
4 changed files with 22 additions and 8 deletions
+6 -3
View File
@@ -72,9 +72,12 @@ func (app *App) RespondWithLink(writer http.ResponseWriter, request *http.Reques
return
}
scheme := "https"
if request.TLS == nil {
scheme = "http"
scheme := request.Header.Get("X-Forwarded-Proto")
if scheme == "" {
scheme = "https"
if request.TLS == nil {
scheme = "http"
}
}
if _, err := fmt.Fprintf(writer, "%s://%s\n", scheme, link); err != nil {