summary refs log tree commit diff
path: root/synapse/federation
diff options
context:
space:
mode:
authorErik Johnston <erikj@jki.re>2019-02-27 15:46:26 +0000
committerGitHub <noreply@github.com>2019-02-27 15:46:26 +0000
commit8267034a63e0d7e33b2a10c1a0660991b448baee (patch)
treeb9cdd345d268191f5a1043acd9f65666cce71fd3 /synapse/federation
parentMerge pull request #4757 from matrix-org/erikj/key_api_fed_readae (diff)
parentNewsfile (diff)
downloadsynapse-8267034a63e0d7e33b2a10c1a0660991b448baee.tar.xz
Merge pull request #4758 from matrix-org/erikj/use_presence_replication
When presence is disabled don't send over replication
Diffstat (limited to 'synapse/federation')
-rw-r--r--synapse/federation/federation_server.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/synapse/federation/federation_server.py b/synapse/federation/federation_server.py
index 569eb277a9..81f3b4b1ff 100644
--- a/synapse/federation/federation_server.py
+++ b/synapse/federation/federation_server.py
@@ -886,6 +886,9 @@ class ReplicationFederationHandlerRegistry(FederationHandlerRegistry):
     def on_edu(self, edu_type, origin, content):
         """Overrides FederationHandlerRegistry
         """
+        if not self.config.use_presence and edu_type == "m.presence":
+            return
+
         handler = self.edu_handlers.get(edu_type)
         if handler:
             return super(ReplicationFederationHandlerRegistry, self).on_edu(