This commit is contained in:
1 parent
d65c9f6998
commit
486781bc5d
1 file changed
+1
-1
@@ -190,7 +190,7 @@ func main() {
|
|||||||
w.Header().Set("Cache-Control", "public; max-age=60")
|
w.Header().Set("Cache-Control", "public; max-age=60")
|
||||||
w.Header().Set("Content-Disposition", "attachment; filename=\""+fileName+"\"")
|
w.Header().Set("Content-Disposition", "attachment; filename=\""+fileName+"\"")
|
||||||
w.WriteHeader(http.StatusOK)
|
w.WriteHeader(http.StatusOK)
|
||||||
json.NewEncoder(w).Encode(content)
|
io.Copy(w, content)
|
||||||
} else {
|
} else {
|
||||||
defer r.Body.Close()
|
defer r.Body.Close()
|
||||||
authKey := r.Header.Get("Authorization")
|
authKey := r.Header.Get("Authorization")
|
||||||
|
|||||||
Reference in new issue
Block a user