From 53be195b158e163791413ecae286646c8161d4c3 Mon Sep 17 00:00:00 2001 From: Seweryn Zeman Date: Mon, 1 Jul 2019 16:10:01 +0200 Subject: [PATCH] Fixed title forwarding --- notify.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/notify.py b/notify.py index a30f07f..be5f456 100644 --- a/notify.py +++ b/notify.py @@ -60,6 +60,8 @@ def __init__(self, pairs, time): def send_message(self, message="", **kwargs): """Send a message.""" + print(kwargs) + mode = MODE_ALL time = self._time data = {} @@ -85,8 +87,15 @@ def send_message(self, message="", **kwargs): if cur_state == STATE_ON or cur_state == STATE_HOME: anyone_home = True + service_data = kwargs + # Append message + service_data['message'] = message + # Alter data + service_data['data'] = data + + print(service_data) + looking_since = dt_util.utcnow() - timedelta(minutes=time) - service_data = {'message': message, 'data': data} # Check and notify each entity for pair in self._pairs: