From 5c749c839d765cca6eea683a261f0a2adeeddbc6 Mon Sep 17 00:00:00 2001 From: Balthasar Reuter Date: Sat, 22 Jun 2019 00:26:14 +0200 Subject: [PATCH] Accepting more upload codes --- photobooth/worker/PictureUploadWebdav.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/photobooth/worker/PictureUploadWebdav.py b/photobooth/worker/PictureUploadWebdav.py index 79bc6661..59938879 100644 --- a/photobooth/worker/PictureUploadWebdav.py +++ b/photobooth/worker/PictureUploadWebdav.py @@ -44,6 +44,6 @@ def do(self, picture, filename): logging.info('Uploading picture as %s', url) r = requests.put(url, data=picture.getbuffer(), auth=self._auth) - if r.status_code != requests.codes.created: + if r.status_code in range(200, 300): logging.warn(('PictureUploadWebdav: Upload failed with ' 'status code {}').format(r.status_code))