Fix python3 compatibility

This commit is contained in:
Vladimir Nadvornik 2017-09-22 10:24:11 +02:00
parent 426eb92474
commit 9d450f7737

View File

@ -112,7 +112,7 @@ def present(name,
ret['result'] = False
return ret
elif len(uuid_dict) == 1:
uuid = uuid_dict.keys()[0]
uuid = list(uuid_dict.keys())[0]
if present and present['uuid'] != uuid:
ret['comment'] = 'Devices MD_UUIDs: {0} differs from present RAID uuid {1}.'.format(uuid, present['uuid'])
ret['result'] = False