diff options
| author | Jenkins <jenkins@review.openstack.org> | 2012-11-21 05:11:42 +0000 |
|---|---|---|
| committer | Gerrit Code Review <review@openstack.org> | 2012-11-21 05:11:42 +0000 |
| commit | cf26ec71a6d4e114b11d1b7b6ddc007f93a9564f (patch) | |
| tree | 9f40f2a5430de65701fa743fe5ab09b9e153da87 /nova/compute | |
| parent | 210afea928bbbda2fe2fb575c76623b9d04e203e (diff) | |
| parent | a19d64808f3c4ab1cc3306ac3678701d0fff3e87 (diff) | |
Merge "Return an error response if the specified flavor does not exists. (v4)"
Diffstat (limited to 'nova/compute')
| -rw-r--r-- | nova/compute/api.py | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/nova/compute/api.py b/nova/compute/api.py index c3b61d0a3..48068eca1 100644 --- a/nova/compute/api.py +++ b/nova/compute/api.py @@ -1128,11 +1128,8 @@ class API(base.Base): filters = {} def _remap_flavor_filter(flavor_id): - try: - instance_type = instance_types.get_instance_type_by_flavor_id( - flavor_id) - except exception.FlavorNotFound: - raise ValueError() + instance_type = instance_types.get_instance_type_by_flavor_id( + flavor_id) filters['instance_type_id'] = instance_type['id'] |
