mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-05-29 20:39:09 -07:00
Added missing else statement that caused existing rules to be discarded
This commit is contained in:
parent
caea50ba4d
commit
103be7ab51
1 changed files with 2 additions and 0 deletions
|
@ -223,6 +223,8 @@ def create_lifecycle_rule(connection, module):
|
||||||
lifecycle_obj.append(rule)
|
lifecycle_obj.append(rule)
|
||||||
changed = True
|
changed = True
|
||||||
appended = True
|
appended = True
|
||||||
|
else:
|
||||||
|
lifecycle_obj.append(existing_rule)
|
||||||
# If nothing appended then append now as the rule must not exist
|
# If nothing appended then append now as the rule must not exist
|
||||||
if not appended:
|
if not appended:
|
||||||
lifecycle_obj.append(rule)
|
lifecycle_obj.append(rule)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue