mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Allow view status from all lamps, if not specified
This commit is contained in:
parent
96adc9cca9
commit
68accf6180
1 changed files with 2 additions and 2 deletions
|
@ -235,8 +235,8 @@ def call_status(*args, **kwargs):
|
|||
Return the status of the lamps.
|
||||
'''
|
||||
res = dict()
|
||||
devices = _get_devices()
|
||||
for dev_id in devices:
|
||||
devices = _get_lights()
|
||||
for dev_id in 'id' not in kwargs and sorted(devices.keys()) or _get_devices(kwargs):
|
||||
res[dev_id] = {
|
||||
'on': devices[dev_id]['state']['on'],
|
||||
'reachable': devices[dev_id]['state']['reachable']
|
||||
|
|
Loading…
Add table
Reference in a new issue