Compare commits

..

No commits in common. "09c8ae421a863bb1055e8199d8b1e54851caaaef" and "54582e46e608213aedf3c494e0d6227796dbbe17" have entirely different histories.

View File

@ -10,7 +10,6 @@ import (
"github.com/spf13/cast"
"net/http"
"net/url"
"strconv"
"strings"
"unicode"
)
@ -51,7 +50,6 @@ func Download(ctx *context.Context, w http.ResponseWriter, req *http.Request) {
}
fileName = safeDownloadName(fileName)
w.Header().Set("Content-Type", "application/octet-stream")
w.Header().Set("Content-Length", strconv.Itoa(len(content)))
w.Header().Set("X-Content-Type-Options", "nosniff")
w.Header().Set("Content-Disposition", fmt.Sprintf("attachment; filename=\"attachment\"; filename*=UTF-8''%s", url.PathEscape(fileName)))
if _, err := w.Write(content); err != nil {