diff --git a/synapse/handlers/profile.py b/synapse/handlers/profile.py index bf91eedb7f..a06f596248 100644 --- a/synapse/handlers/profile.py +++ b/synapse/handlers/profile.py @@ -45,16 +45,14 @@ class ProfileHandler(BaseHandler): self.http_client = hs.get_simple_http_client() - self.clock.looping_call(self._update_remote_profile_cache, self.PROFILE_UPDATE_MS) - if hs.config.worker_app is None: self.clock.looping_call( self._update_remote_profile_cache, self.PROFILE_UPDATE_MS, ) - reactor.callWhenRunning(self._assign_profile_replication_batches) - reactor.callWhenRunning(self._replicate_profiles) - self.clock.looping_call(self._replicate_profiles, self.PROFILE_REPLICATE_INTERVAL) + reactor.callWhenRunning(self._assign_profile_replication_batches) + reactor.callWhenRunning(self._replicate_profiles) + self.clock.looping_call(self._replicate_profiles, self.PROFILE_REPLICATE_INTERVAL) @defer.inlineCallbacks def _assign_profile_replication_batches(self):