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

simplified bad if chain hopefully fixes #1136

This commit is contained in:
Brian Coca 2015-04-14 13:18:46 -04:00 committed by Matt Clay
parent 06579c560e
commit a6107e35e9

View file

@ -703,14 +703,10 @@ class LinuxService(Service):
# Check if we're already in the correct state # Check if we're already in the correct state
service_enabled = self.get_systemd_service_enabled() service_enabled = self.get_systemd_service_enabled()
if self.enable and service_enabled:
self.changed = False
elif not self.enable and not service_enabled:
self.changed = False
elif not self.enable:
self.changed = False
if not self.changed: # self.changed should already be true
if self.enable == service_enabled:
self.changed = False
return return
# #