diff options
author | Evgeny Kuznetsov <evgeny@kuznetsov.md> | 2023-03-23 20:23:59 +0300 |
---|---|---|
committer | Evgeny Kuznetsov <evgeny@kuznetsov.md> | 2023-03-23 20:23:59 +0300 |
commit | 93acbe74a992c4cb83676301e084575bd4fe76e5 (patch) | |
tree | b30dbea8da6b15301f4d89384b8505abed1e0edd | |
parent | e1e1498c97c929821c3b84ff7dd1753fe3180ce4 (diff) | |
download | static-wm-93acbe74a992c4cb83676301e084575bd4fe76e5.tar.gz static-wm-93acbe74a992c4cb83676301e084575bd4fe76e5.zip |
chore: satisfy linters
-rw-r--r-- | main.go | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -29,18 +29,18 @@ func (ep endpoint) ServeHTTP(w http.ResponseWriter, r *http.Request) { if source.Scheme != "http" && source.Scheme != "https" { w.WriteHeader(http.StatusBadRequest) - w.Write([]byte(errInvalidScheme)) + _, _ = w.Write([]byte(errInvalidScheme)) return } target, err := url.Parse(r.PostFormValue("target")) if err != nil || !ep.targetAllowed(target) { w.WriteHeader(http.StatusBadRequest) - w.Write([]byte(errTgtNotAccepted)) + _, _ = w.Write([]byte(errTgtNotAccepted)) return } if target.Scheme != "http" && target.Scheme != "https" { w.WriteHeader(http.StatusBadRequest) - w.Write([]byte(errInvalidScheme)) + _, _ = w.Write([]byte(errInvalidScheme)) return } } |