fix multiple server delete produce multiple new lines

Closes-Bug: #1809874
Change-Id: Ib988b189b41af03d3d871b660bb5b5cc090c3f30
This commit is contained in:
Noam Angel 2018-12-27 08:35:45 +00:00 committed by Dean Troyer
parent 7b72fb816f
commit 7276610595

View File

@ -999,13 +999,9 @@ class DeleteServer(command.Command):
compute_client.servers, server)
compute_client.servers.delete(server_obj.id)
if parsed_args.wait:
if utils.wait_for_delete(
compute_client.servers,
server_obj.id,
callback=_show_progress,
):
self.app.stdout.write('\n')
else:
if not utils.wait_for_delete(compute_client.servers,
server_obj.id,
callback=_show_progress):
LOG.error(_('Error deleting server: %s'),
server_obj.id)
self.app.stdout.write(_('Error deleting server\n'))