From 3a487a83676f4e668af1edc9dd6256ce562fb840 Mon Sep 17 00:00:00 2001 From: Ryan Peters Date: Wed, 23 Apr 2014 10:18:12 -0500 Subject: [PATCH] Fixes incorrect processing of deleting metadata When a non-admin tries to delete metadata from a marked image, they are correctly getting an error message, however they are also getting a success message when they shouldn't. This code fixes the incorrect success message. Closes-Bug: #1308519 Change-Id: I909551365b4a92675d26c1da754e586685a4aa32 --- muranodashboard/images/tables.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/muranodashboard/images/tables.py b/muranodashboard/images/tables.py index 0c9a9ff2a..3587e6e3f 100644 --- a/muranodashboard/images/tables.py +++ b/muranodashboard/images/tables.py @@ -36,7 +36,8 @@ class RemoveImageMetadata(tables.DeleteAction): try: glance.image_update(request, obj_id, properties={}) except Exception: - exceptions.handle(request, _('Unable to remove metadata')) + exceptions.handle(request, _('Unable to remove metadata'), + redirect='horizon:murano:images:index') class MarkedImagesTable(tables.DataTable):