Mercurial > libervia-web
changeset 1428:b028a1256a09
browser (photos/album): show directly failure's message on upload error, and remove photo
author | Goffi <goffi@goffi.org> |
---|---|
date | Wed, 05 May 2021 15:43:44 +0200 |
parents | eaf36fffcbdb |
children | 01936fc55cd9 |
files | libervia/pages/photos/album/_browser/__init__.py |
diffstat | 1 files changed, 3 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/libervia/pages/photos/album/_browser/__init__.py Sat May 01 19:05:16 2021 +0200 +++ b/libervia/pages/photos/album/_browser/__init__.py Wed May 05 15:43:44 2021 +0200 @@ -45,7 +45,7 @@ def on_error(failure, file_, photo_elt): dialog.notification.show( - f"can't upload {file_.name}: failure", + f"can't upload {file_.name}: {failure}", level="error" ) @@ -70,9 +70,10 @@ def on_slot_eb(file_, failure, photo_elt): dialog.notification.show( - f"Can't get upload slot: {failure}", + f"Can't get upload slot: {failure['message']}", level="error" ) + photo_elt.remove() def upload_files(files):