From 2da4aa99aaca3debcda1d046b7806a8f83ac8090 Mon Sep 17 00:00:00 2001 From: Stephen Finucane Date: Fri, 7 Oct 2022 17:12:39 +0100 Subject: quota: Fix issues with delete quota command We were passing a project object rather than just the ID. Also correct a typo in the call to delete network quotas. Change-Id: I2292db7932ec01026f0e54014e3d02218792617a Signed-off-by: Stephen Finucane --- openstackclient/common/quota.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'openstackclient/common') diff --git a/openstackclient/common/quota.py b/openstackclient/common/quota.py index 10f40a75..f2d097fc 100644 --- a/openstackclient/common/quota.py +++ b/openstackclient/common/quota.py @@ -972,12 +972,12 @@ class DeleteQuota(command.Command): # compute quotas if parsed_args.service in {'all', 'compute'}: compute_client = self.app.client_manager.compute - compute_client.quotas.delete(project) + compute_client.quotas.delete(project.id) # volume quotas if parsed_args.service in {'all', 'volume'}: volume_client = self.app.client_manager.volume - volume_client.quotas.delete(project) + volume_client.quotas.delete(project.id) # network quotas (but only if we're not using nova-network, otherwise # we already deleted the quotas in the compute step) @@ -986,6 +986,6 @@ class DeleteQuota(command.Command): and self.app.client_manager.is_network_endpoint_enabled() ): network_client = self.app.client_manager.network - network_client.quotas.delete(project) + network_client.delete_quota(project.id) return None -- cgit v1.2.1