Properly fail an upload when it is too large.

This commit is contained in:
Justin Hawkins 2021-10-19 22:39:27 +10:30
parent c3f1813f6e
commit 672fd83f27

View File

@ -144,6 +144,7 @@ func (u *Upload) processUpload() error {
if resp.StatusCode == 413 {
// just fail immediately, we know this means the file was too big
daulog.SendLog("413 received - file too large", daulog.LogTypeError)
u.Failed = true
return errors.New("received 413 - file too large")
}