Browse files

Merge "Handle server_id and serverId in volume list" into milestone-p…

  • Loading branch information...
Jenkins authored and openstack-gerrit committed Mar 28, 2012
2 parents 10d226f + dcd9065 commit 45fb6b6de89eaec642ecbf755af45fd55f8224d4
Showing with 2 additions and 1 deletion.
  1. +2 −1 novaclient/v1_1/
@@ -860,7 +860,8 @@ def do_volume_list(cs, args):
# Create a list of servers to which the volume is attached
for vol in volumes:
- servers = [server.get('serverId') for server in vol.attachments]
+ servers = [s.get('server_id') or s.get('serverId')
+ for s in vol.attachments]
setattr(vol, 'attached_to', ','.join(map(str, servers)))
utils.print_list(volumes, ['ID', 'Status', 'Display Name',
'Size', 'Volume Type', 'Attached to'])

0 comments on commit 45fb6b6

Please sign in to comment.