mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
fixed parsing issue with openstacksdk and idempotent checking issues (#44928)
* fixed parsing issue with openstacksdk and idempotent checking issues * fixed whitespace found in pylint
This commit is contained in:
parent
d9a17e098c
commit
ca918def18
1 changed files with 4 additions and 4 deletions
|
@ -130,11 +130,11 @@ def _system_state_change(state, records, description, ttl, zone, recordset):
|
|||
if state == 'present':
|
||||
if recordset is None:
|
||||
return True
|
||||
if records is not None and recordset.records != records:
|
||||
if records is not None and recordset['records'] != records:
|
||||
return True
|
||||
if description is not None and recordset.description != description:
|
||||
if description is not None and recordset['description'] != description:
|
||||
return True
|
||||
if ttl is not None and recordset.ttl != ttl:
|
||||
if ttl is not None and recordset['ttl'] != ttl:
|
||||
return True
|
||||
if state == 'absent' and recordset:
|
||||
return True
|
||||
|
@ -169,7 +169,7 @@ def main():
|
|||
recordset_type = module.params.get('recordset_type')
|
||||
recordset_filter = {'type': recordset_type}
|
||||
|
||||
recordsets = cloud.search_recordsets(zone, name_or_id=name + '.' + zone, filters=recordset_filter)
|
||||
recordsets = cloud.search_recordsets(zone, name_or_id=name, filters=recordset_filter)
|
||||
|
||||
if len(recordsets) == 1:
|
||||
recordset = recordsets[0]
|
||||
|
|
Loading…
Reference in a new issue