From 9a47367e2051cd54f9e520f9eb034e260de869b9 Mon Sep 17 00:00:00 2001 From: Kengo Takahara Date: Fri, 24 Feb 2017 17:26:59 +0900 Subject: [PATCH] Change the base class of osc.v1.DeleteHost Since the function to delete a segment host doesn't output resources after processing, the base class of DeleteHost class should be the osc_lib.command.command.Command class. This patch modified the base class of DeleteHost class and modified so that it doesn't return an unnecessary value. Change-Id: I2fcce95ae25be94ee5c38b876574476b77fdedff Closes-Bug: #1656762 --- masakariclient/osc/v1/host.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/masakariclient/osc/v1/host.py b/masakariclient/osc/v1/host.py index cdd2813..01a8225 100644 --- a/masakariclient/osc/v1/host.py +++ b/masakariclient/osc/v1/host.py @@ -242,7 +242,7 @@ class UpdateHost(command.ShowOne): return _show_host(masakari_client, parsed_args.segment_id, uuid) -class DeleteHost(command.ShowOne): +class DeleteHost(command.Command): """Delete a host.""" def get_parser(self, prog_name): @@ -267,7 +267,6 @@ class DeleteHost(command.ShowOne): segment=parsed_args.segment_id) masakari_client.delete_host(parsed_args.segment_id, uuid, False) print('Host deleted: %s' % parsed_args.host) - return ({}, {}) def _show_host(masakari_client, segment_id, uuid):