From decee66cb412cafecddc581cd8f229e77a9c6f1a Mon Sep 17 00:00:00 2001 From: Alessio Ababilov Date: Mon, 20 May 2013 16:33:58 +0300 Subject: [PATCH] Always return a list from VolumeTableMixIn._get* Returning None from these methods leads to TypeError (None is not iterable) Fixes: bug #1182075 Change-Id: Ia5f5fe78669bbaed599b7dd5cae1beb69bde7796 --- openstack_dashboard/dashboards/project/volumes/views.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/openstack_dashboard/dashboards/project/volumes/views.py b/openstack_dashboard/dashboards/project/volumes/views.py index f25c822412..fedaeea378 100644 --- a/openstack_dashboard/dashboards/project/volumes/views.py +++ b/openstack_dashboard/dashboards/project/volumes/views.py @@ -47,6 +47,7 @@ class VolumeTableMixIn(object): except: exceptions.handle(self.request, _('Unable to retrieve volume list.')) + return [] def _get_instances(self): try: @@ -56,6 +57,7 @@ class VolumeTableMixIn(object): exceptions.handle(self.request, _("Unable to retrieve volume/instance " "attachment information")) + return [] def _set_id_if_nameless(self, volumes, instances): for volume in volumes: