More robust detection of jitsi call

This commit is contained in:
Ville Ranki 2020-07-21 00:24:40 +03:00
parent f74f3a6df7
commit d74522ec0c
1 changed files with 1 additions and 1 deletions

View File

@ -16,7 +16,7 @@ class MatrixModule(BotModule):
bot.remove_callback(self.unknownevent_cb) bot.remove_callback(self.unknownevent_cb)
async def unknownevent_cb(self, room, event): async def unknownevent_cb(self, room, event):
if event.type == 'im.vector.modular.widgets' and event.source['content']['type'] == 'jitsi': if 'type' in event.source and event.source['type'] == 'im.vector.modular.widgets' and event.source['content']['type'] == 'jitsi':
domain = event.source['content']['data']['domain'] domain = event.source['content']['data']['domain']
conferenceId = event.source['content']['data']['conferenceId'] conferenceId = event.source['content']['data']['conferenceId']
isAudioOnly = event.source['content']['data']['isAudioOnly'] isAudioOnly = event.source['content']['data']['isAudioOnly']