mirror of
https://github.com/valitydev/salt.git
synced 2024-11-08 01:18:58 +00:00
Fix dict iteration bug introduced in pull request #1908.
This commit is contained in:
parent
f510dcbc2f
commit
c528f690f4
@ -59,7 +59,7 @@ def get_enabled():
|
||||
salt '*' service.get_enabled
|
||||
'''
|
||||
ret = []
|
||||
for name, state in enumerate(_get_all_unit_files()):
|
||||
for name, state in _get_all_unit_files().iteritems():
|
||||
if state == 'enabled':
|
||||
ret.append(name)
|
||||
return sorted(ret)
|
||||
@ -74,7 +74,7 @@ def get_disabled():
|
||||
salt '*' service.get_disabled
|
||||
'''
|
||||
ret = []
|
||||
for name, state in enumerate(_get_all_unit_files()):
|
||||
for name, state in _get_all_unit_files().iteritems():
|
||||
if state == 'disabled':
|
||||
ret.append(name)
|
||||
return sorted(ret)
|
||||
|
Loading…
Reference in New Issue
Block a user