SYN-513: Include updates for rooms that have had all their tags deleted

pull/354/head
Mark Haines 2015-11-09 14:52:18 +00:00
parent 5335bf9c34
commit c4135d85e1
2 changed files with 2 additions and 2 deletions

View File

@ -272,7 +272,7 @@ class SyncHandler(BaseHandler):
def private_user_data_for_room(self, room_id, tags_by_room):
private_user_data = []
tags = tags_by_room.get(room_id)
if tags:
if tags is not None:
private_user_data.append({
"type": "m.tag",
"content": {"tags": tags},

View File

@ -95,7 +95,7 @@ class TagsStore(SQLBaseStore):
if room_ids:
tags_by_room = yield self.get_tags_for_user(user_id)
for room_id in room_ids:
results[room_id] = tags_by_room[room_id]
results[room_id] = tags_by_room.get(room_id, {})
defer.returnValue(results)