Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
"return": lambda p: [InputSource(x) for x in p["devices"]],
},
return request_func
class SourceControl(WebOSControlBase):
COMMANDS = {
"list_sources": {
"uri": "ssap://tv/getExternalInputList",
"args": [],
"kwargs": {},
"payload": {},
"validation": standard_validation,
"return": lambda p: [InputSource(x) for x in p["devices"]],
},
"set_source": {
"uri": "ssap://tv/switchInput",
"args": [InputSource],
"kwargs": {},
"payload": {
"inputId": arguments(0, postprocess=lambda inp: inp["id"]),
},
"validation": standard_validation,
},