def _expand_disk(disk):
 ret = {}
 ret.update(disk.__dict__)
 zone = ret['extra']['zone']
 ret['extra']['zone'] = {}
 ret['extra']['zone'].update(zone.__dict__)
 return ret

def _expand_disk ( disk ) : ret = { } ret . update ( disk . __dict__ ) zone = ret [ 'extra' ] [ 'zone' ] ret [ 'extra' ] [ 'zone' ] = { } ret [ 'extra' ] [ 'zone' ] . update ( zone . __dict__ ) return ret
convert the libcloud volume object into something more serializable .