diff options
Diffstat (limited to 'mediaapi/routing/upload.go')
-rw-r--r-- | mediaapi/routing/upload.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mediaapi/routing/upload.go b/mediaapi/routing/upload.go index ecdab219..f762b2ff 100644 --- a/mediaapi/routing/upload.go +++ b/mediaapi/routing/upload.go @@ -169,7 +169,7 @@ func (r *uploadRequest) doUpload( } // Check if temp file size exceeds max file size configuration - if bytesWritten > types.FileSizeBytes(*cfg.MaxFileSizeBytes) { + if *cfg.MaxFileSizeBytes > 0 && bytesWritten > types.FileSizeBytes(*cfg.MaxFileSizeBytes) { fileutils.RemoveDir(tmpDir, r.Logger) // delete temp file return requestEntityTooLargeJSONResponse(*cfg.MaxFileSizeBytes) } |