power: fetch the Smart Things token option as a template

This allows users to store their token in a "secrets" file

Signed-off-by:  Eric Callahan <arksine.code@gmail.com>
This commit is contained in:
Eric Callahan 2022-02-14 06:19:37 -05:00
parent 0dc05eac76
commit 10703321b0
1 changed files with 1 additions and 1 deletions

View File

@ -951,7 +951,7 @@ class SmartThings(HTTPDevice):
def __init__(self, config: ConfigHelper) -> None: def __init__(self, config: ConfigHelper) -> None:
super().__init__(config, default_port=443, default_protocol="https") super().__init__(config, default_port=443, default_protocol="https")
self.device: str = config.get("device", "") self.device: str = config.get("device", "")
self.token: str = config.get("token", "") self.token: str = config.gettemplate("token").render()
async def _send_smartthings_command(self, async def _send_smartthings_command(self,
command: str command: str