From 6b7e539177038fb72a6df8c93d35854dcc06bd58 Mon Sep 17 00:00:00 2001 From: Greg Price Date: Sat, 19 Dec 2009 22:30:08 -0500 Subject: [PATCH] command: recognize new "internal" name for delete This fixes the bug where delete leads back to the now-broken info page. svn path=/package_branches/invirt-web/cherrypy-rebased/; revision=2726 --- code/main.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/main.py b/code/main.py index 7c04d25..3be15a6 100755 --- a/code/main.py +++ b/code/main.py @@ -353,12 +353,12 @@ console will suffer artifacts. def command(self, command_name, machine_id, **kwargs): """Handler for running commands like boot and delete on a VM.""" back = kwargs.get('back') + if command_name == 'delete': + back = 'list' try: d = controls.commandResult(cherrypy.request.login, cherrypy.request.state, command_name, machine_id, kwargs) - if d['command'] == 'Delete VM': - back = 'list' except InvalidInput, err: if not back: raise -- 1.7.9.5