1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Proper check for update_config

This commit is contained in:
kaikash 2024-08-04 17:03:55 +03:00
parent c517f1c483
commit 70ca43a5e1

View file

@ -818,6 +818,10 @@ class ProxmoxLxcAnsible(ProxmoxAnsible):
if new_value not in current_values: if new_value not in current_values:
update_config = True update_config = True
break break
# Check if current values have more elements than requested values
if len(current_values) != len(requested_values):
update_config = True
# if it's not a list (or string) just compare the current value # if it's not a list (or string) just compare the current value
else: else:
# some types don't match with the API, so forcing to string for comparison # some types don't match with the API, so forcing to string for comparison