mirror of
https://github.com/valitydev/salt.git
synced 2024-11-09 01:36:48 +00:00
Merge pull request #5077 from hulu/winserv-status-shadowing
win_service mod: status -> statuses, to avoid shadowing same-named func
This commit is contained in:
commit
9f1384f3b6
@ -184,8 +184,8 @@ def status(name, sig=None):
|
||||
salt '*' service.status <service name> [service signature]
|
||||
'''
|
||||
cmd = 'sc query "{0}"'.format(name)
|
||||
status = __salt__['cmd.run'](cmd).splitlines()
|
||||
for line in status:
|
||||
statuses = __salt__['cmd.run'](cmd).splitlines()
|
||||
for line in statuses:
|
||||
if 'RUNNING' in line:
|
||||
return getsid(name)
|
||||
elif 'PENDING' in line:
|
||||
|
Loading…
Reference in New Issue
Block a user