From: Kevin Benton Date: Tue, 15 Sep 2015 17:13:38 +0000 (-0700) Subject: Add missing resource discriminator in update resp X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=3b8fdf4eaaa3262147a61fa1f2e6debb22ed0cf1;p=openstack-build%2Fneutron-build.git Add missing resource discriminator in update resp The update method of the pecan itemcontroller was not returning the response encapsulated correctly in a dictionary with the resource type identifier. This was discovered via the standard API tests. Change-Id: Ie2217972c75b14a0867477f26f434055b33a9ae6 --- diff --git a/neutron/pecan_wsgi/controllers/root.py b/neutron/pecan_wsgi/controllers/root.py index 396778bac..420fdf5a7 100644 --- a/neutron/pecan_wsgi/controllers/root.py +++ b/neutron/pecan_wsgi/controllers/root.py @@ -165,7 +165,8 @@ class ItemController(object): request.prepared_data) # TODO(kevinbenton): bulk? updater = getattr(request.plugin, 'update_%s' % request.resource_type) - return updater(request.context, self.item, request.prepared_data) + return {request.resource_type: updater( + request.context, self.item, request.prepared_data)} @when(index, method='DELETE') def delete(self):