diff options
| author | zheng yin <yin.zheng@easystack.cn> | 2016-08-02 21:14:17 +0800 |
|---|---|---|
| committer | ChangBo Guo(gcb) <glongwave@gmail.com> | 2016-09-26 04:30:58 +0000 |
| commit | e5b347c658d339bd335abf64175e1c87529ad0e2 (patch) | |
| tree | 68ef5175a946530b8f4aa9a01f234692f36d6008 /cinderclient/v1 | |
| parent | b174967f91c3a43de70091fddc1cfaba88ea359b (diff) | |
| download | python-cinderclient-e5b347c658d339bd335abf64175e1c87529ad0e2.tar.gz | |
remove raise "e"
when it has an exception, it will call raise without arguments.
we can use "raise" replace "raise e", the result is the same.
Change-Id: I329932dcb2f49dcd3f0dfd88a5896860322e60ec
Diffstat (limited to 'cinderclient/v1')
| -rw-r--r-- | cinderclient/v1/shell.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/cinderclient/v1/shell.py b/cinderclient/v1/shell.py index 3776fa1..9939187 100644 --- a/cinderclient/v1/shell.py +++ b/cinderclient/v1/shell.py @@ -1142,11 +1142,11 @@ def do_availability_zone_list(cs, _args): """Lists all availability zones.""" try: availability_zones = cs.availability_zones.list() - except exceptions.Forbidden as e: # policy doesn't allow probably + except exceptions.Forbidden: # policy doesn't allow probably try: availability_zones = cs.availability_zones.list(detailed=False) except Exception: - raise e + raise result = [] for zone in availability_zones: |
