From 8743f23f1369d75d43eb77fe17cc3281f32da7c1 Mon Sep 17 00:00:00 2001 From: Alan Fischer Date: Thu, 2 Mar 2017 01:22:38 -0700 Subject: [PATCH] Fix calendar authentication text, and handle calendar events without summaries. (#6337) * Fixed google authorization text * Let calendar handle events without a summary --- homeassistant/components/calendar/__init__.py | 2 +- homeassistant/components/google.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/homeassistant/components/calendar/__init__.py b/homeassistant/components/calendar/__init__.py index 1aefc11d9c0..70477198ea0 100644 --- a/homeassistant/components/calendar/__init__.py +++ b/homeassistant/components/calendar/__init__.py @@ -155,7 +155,7 @@ class CalendarEventDevice(Entity): start = _get_date(self.data.event['start']) end = _get_date(self.data.event['end']) - summary = self.data.event['summary'] + summary = self.data.event.get('summary', '') # check if we have an offset tag in the message # time is HH:MM or MM diff --git a/homeassistant/components/google.py b/homeassistant/components/google.py index 10a335ff7a2..e72eca9e7fa 100644 --- a/homeassistant/components/google.py +++ b/homeassistant/components/google.py @@ -118,8 +118,8 @@ def do_authentication(hass, config): return False persistent_notification.create( - hass, 'In order to authorize Home-Assistant to view your calendars' - 'You must visit: {} and enter' + hass, 'In order to authorize Home-Assistant to view your calendars ' + 'you must visit: {} and enter ' 'code: {}'.format(dev_flow.verification_url, dev_flow.verification_url, dev_flow.user_code),