summaryrefslogtreecommitdiff
path: root/nova/api/openstack/compute/server_migrations.py
diff options
context:
space:
mode:
Diffstat (limited to 'nova/api/openstack/compute/server_migrations.py')
-rw-r--r--nova/api/openstack/compute/server_migrations.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/nova/api/openstack/compute/server_migrations.py b/nova/api/openstack/compute/server_migrations.py
index 230d6088fe..4f404f8944 100644
--- a/nova/api/openstack/compute/server_migrations.py
+++ b/nova/api/openstack/compute/server_migrations.py
@@ -139,7 +139,7 @@ class ServerMigrationsController(wsgi.Controller):
# TODO(Shaohe Feng) we should share the in-progress list.
in_progress = ['queued', 'preparing', 'running', 'post-migrating']
- if migration.get("status") not in in_progress:
+ if migration.status not in in_progress:
msg = _("Live migration %(id)s for server %(uuid)s is not in"
" progress.") % {"id": id, "uuid": server_id}
raise exc.HTTPNotFound(explanation=msg)