summary refs log tree commit diff
path: root/synapse/handlers
diff options
context:
space:
mode:
authorAndrew Morgan <1342360+anoadragon453@users.noreply.github.com>2023-03-03 10:51:57 +0000
committerGitHub <noreply@github.com>2023-03-03 10:51:57 +0000
commit15e975f68fc354843a0647e53f285696e86de89b (patch)
treef037a37ccf13170d6bb9bd72d509e557c8fb2cc5 /synapse/handlers
parentAdd a `get_next_txn` method to `StreamIdGenerator` to match `MultiWriterIdGen... (diff)
downloadsynapse-15e975f68fc354843a0647e53f285696e86de89b.tar.xz
Experimental MSC3890 Implementation: Fix deleting account data when using an account data writer worker (#14869)
Diffstat (limited to 'synapse/handlers')
-rw-r--r--synapse/handlers/account_data.py7
1 files changed, 0 insertions, 7 deletions
diff --git a/synapse/handlers/account_data.py b/synapse/handlers/account_data.py
index 797de46dbc..7e01c18c6c 100644
--- a/synapse/handlers/account_data.py
+++ b/synapse/handlers/account_data.py
@@ -155,9 +155,6 @@ class AccountDataHandler:
             max_stream_id = await self._store.remove_account_data_for_room(
                 user_id, room_id, account_data_type
             )
-            if max_stream_id is None:
-                # The referenced account data did not exist, so no delete occurred.
-                return None
 
             self._notifier.on_new_event(
                 StreamKeyType.ACCOUNT_DATA, max_stream_id, users=[user_id]
@@ -230,9 +227,6 @@ class AccountDataHandler:
             max_stream_id = await self._store.remove_account_data_for_user(
                 user_id, account_data_type
             )
-            if max_stream_id is None:
-                # The referenced account data did not exist, so no delete occurred.
-                return None
 
             self._notifier.on_new_event(
                 StreamKeyType.ACCOUNT_DATA, max_stream_id, users=[user_id]
@@ -248,7 +242,6 @@ class AccountDataHandler:
                 instance_name=random.choice(self._account_data_writers),
                 user_id=user_id,
                 account_data_type=account_data_type,
-                content={},
             )
             return response["max_stream_id"]