From c082888d2a9810c61400fa909d25cbc97ad44371 Mon Sep 17 00:00:00 2001 From: Rich O Date: Wed, 27 Nov 2019 14:36:22 -0500 Subject: [PATCH] fixing variable calling --- r0b3bot.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/r0b3bot.py b/r0b3bot.py index e787be9..8f41360 100644 --- a/r0b3bot.py +++ b/r0b3bot.py @@ -255,7 +255,7 @@ async def printstat(ctx): #remote.call_service(hassapi, 'switch', 'turn_on', {'entity_id':'{}'.format(HASS_LIGHT)}) hassAPIRUL = HASS_IP_ADDRESS + "/api/services/switch/turn_on" payload = { - "entity": HASS_LIGHT + "entity": f"{HASS_LIGHT}" } requests.post(hassAPIURL, data=payload, headers=hassHEADERS) except: @@ -289,7 +289,7 @@ async def printstat(ctx): #remote.call_service(hassapi, 'switch', 'turn_on', {'entity_id':'{}'.format(HASS_LIGHT)}) hassAPIRUL = HASS_IP_ADDRESS + "/api/services/switch/turn_off" payload = { - "entity": HASS_LIGHT + "entity": f"{HASS_LIGHT}" } requests.post(hassAPIURL, data=payload, headers=hassHEADERS) except: -- 2.39.5