From 672fd83f270dcf88b605232dd4d8d31edc247dc2 Mon Sep 17 00:00:00 2001 From: Justin Hawkins Date: Tue, 19 Oct 2021 22:39:27 +1030 Subject: [PATCH] Properly fail an upload when it is too large. --- upload/upload.go | 1 + 1 file changed, 1 insertion(+) diff --git a/upload/upload.go b/upload/upload.go index d5143b7..eafca1c 100644 --- a/upload/upload.go +++ b/upload/upload.go @@ -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") }