mirror of
https://github.com/home-assistant/core.git
synced 2025-06-18 03:57:10 +00:00
Fix HassIO bug with supervisor update & log (#7282)
This commit is contained in:
parent
215987d5a7
commit
f58d200ecb
@ -122,7 +122,8 @@ def async_setup(hass, config):
|
||||
yield from hassio.send_command("/host/shutdown")
|
||||
elif service.service == SERVICE_SUPERVISOR_UPDATE:
|
||||
yield from hassio.send_command(
|
||||
"/supervisor/update", payload=version)
|
||||
"/supervisor/update", payload=version,
|
||||
timeout=LONG_TASK_TIMEOUT)
|
||||
elif service.service == SERVICE_SUPERVISOR_RELOAD:
|
||||
yield from hassio.send_command(
|
||||
"/supervisor/reload", timeout=LONG_TASK_TIMEOUT)
|
||||
@ -183,8 +184,9 @@ class HassIO(object):
|
||||
)
|
||||
if answer and answer['result'] == 'ok':
|
||||
return answer['data'] if answer['data'] else True
|
||||
elif answer:
|
||||
_LOGGER.error("%s return error %s.", cmd, answer['message'])
|
||||
|
||||
_LOGGER.error("%s return error %s.", cmd, answer['message'])
|
||||
return False
|
||||
|
||||
@asyncio.coroutine
|
||||
|
Loading…
x
Reference in New Issue
Block a user