From 79a1980cae334fbecbdeebe986f5db17bab221b7 Mon Sep 17 00:00:00 2001 From: Erik Cederstrand Date: Sat, 22 May 2021 14:10:43 +0200 Subject: [PATCH] Pull in upstream commit 2dc1deee Fix for Clubhouse story 58700 --- exchangelib/properties.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/exchangelib/properties.py b/exchangelib/properties.py index 69a55f7..a4abffc 100644 --- a/exchangelib/properties.py +++ b/exchangelib/properties.py @@ -647,15 +647,17 @@ class FreeBusyView(EWSElement): @classmethod def from_xml(cls, elem, account): kwargs = {} + working_hours_elem = elem.find('{%s}WorkingHours' % TNS) for f in cls.FIELDS: if f.name == 'working_hours': - kwargs[f.name] = f.from_xml(elem=elem.find('{%s}WorkingHours' % TNS), account=account) + if working_hours_elem is None: + continue + kwargs[f.name] = f.from_xml(elem=working_hours_elem, account=account) continue kwargs[f.name] = f.from_xml(elem=elem, account=account) elem.clear() return cls(**kwargs) - class RoomList(Mailbox): # MSDN: https://msdn.microsoft.com/en-us/library/office/dd899514(v=exchg.150).aspx ELEMENT_NAME = 'RoomList'