From 7b11eeffeff1daeebfe02d2358588b5c1ea7ce81 Mon Sep 17 00:00:00 2001 From: Michel Roux Date: Tue, 29 Sep 2020 17:21:44 +0200 Subject: [PATCH] Fix crash on delete --- pynyaata/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pynyaata/__init__.py b/pynyaata/__init__.py index 2fc121d..313a8f0 100644 --- a/pynyaata/__init__.py +++ b/pynyaata/__init__.py @@ -128,8 +128,8 @@ def admin(): if link: db.session.delete(link) db.session.commit() - remove_garbage(link) form.message = '%s (%s) has been successfully deleted' % (link.title.name, link.season) + remove_garbage(link) else: form._errors = {'id': ['Id %s was not found in the database' % form.id.data]}