Skip to content
Snippets Groups Projects
Commit 87d26dc9 authored by Travis Ralston's avatar Travis Ralston
Browse files

Setting the max size to 0 should disable the max size

parent 9649f8d3
No related branches found
No related tags found
No related merge requests found
......@@ -34,7 +34,9 @@ func UploadMedia(w http.ResponseWriter, r *http.Request, db storage.Database, c
contentType = "application/octet-stream" // binary
}
r.Body = http.MaxBytesReader(w, r.Body, c.Uploads.MaxSizeBytes)
if c.Uploads.MaxSizeBytes > 0 {
r.Body = http.MaxBytesReader(w, r.Body, c.Uploads.MaxSizeBytes)
}
request := &media_handler.MediaUploadRequest{
UploadedBy: "",
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment