summary refs log tree commit diff
path: root/synapse/handlers/auth.py
diff options
context:
space:
mode:
Diffstat (limited to 'synapse/handlers/auth.py')
-rw-r--r--synapse/handlers/auth.py21
1 files changed, 3 insertions, 18 deletions
diff --git a/synapse/handlers/auth.py b/synapse/handlers/auth.py

index 8da017c3ba..ddbfbb2c18 100644 --- a/synapse/handlers/auth.py +++ b/synapse/handlers/auth.py
@@ -1595,9 +1595,9 @@ class AuthHandler: # has successfully been created. await self._third_party_rules.on_threepid_bind(user_id, medium, address) - async def delete_and_unbind_threepid( - self, user_id: str, medium: str, address: str, id_server: Optional[str] = None - ) -> bool: + async def delete_local_threepid( + self, user_id: str, medium: str, address: str + ) -> None: """Attempts to unbind the 3pid on the identity servers and deletes it from the local database. @@ -1605,25 +1605,11 @@ class AuthHandler: user_id: ID of user to remove the 3pid from. medium: The medium of the 3pid being removed: "email" or "msisdn". address: The 3pid address to remove. - id_server: Use the given identity server when unbinding - any threepids. If None then will attempt to unbind using the - identity server specified when binding (if known). - - Returns: - Returns True if successfully unbound the 3pid on - the identity server, False if identity server doesn't support the - unbind API. """ - # 'Canonicalise' email addresses as per above if medium == "email": address = canonicalise_email(address) - identity_handler = self.hs.get_identity_handler() - result = await identity_handler.try_unbind_threepid( - user_id, {"medium": medium, "address": address, "id_server": id_server} - ) - # Inform Synapse modules that a 3PID association is about to be deleted. await self._third_party_rules.on_remove_user_third_party_identifier( user_id, medium, address @@ -1643,7 +1629,6 @@ class AuthHandler: await self.store.delete_pusher_by_app_id_pushkey_user_id( app_id="m.email", pushkey=address, user_id=user_id ) - return result async def hash(self, password: str) -> str: """Computes a secure hash of password.