diff options
author | Amber Brown <hawkowl@atleastfornow.net> | 2018-08-13 16:47:46 +1000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-08-13 16:47:46 +1000 |
commit | 99dd975dae7baaaef2a3b0a92fa51965b121ae34 (patch) | |
tree | 31fff38e9be8ffb8d4407b02cdf9a07247a11f1b /synapse/storage/client_ips.py | |
parent | Merge pull request #3679 from matrix-org/hawkowl/blackify-tests (diff) | |
download | synapse-99dd975dae7baaaef2a3b0a92fa51965b121ae34.tar.xz |
Run tests under PostgreSQL (#3423)
Diffstat (limited to 'synapse/storage/client_ips.py')
-rw-r--r-- | synapse/storage/client_ips.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/synapse/storage/client_ips.py b/synapse/storage/client_ips.py index 2489527f2c..8fc678fa67 100644 --- a/synapse/storage/client_ips.py +++ b/synapse/storage/client_ips.py @@ -96,6 +96,11 @@ class ClientIpStore(background_updates.BackgroundUpdateStore): self._batch_row_update[key] = (user_agent, device_id, now) def _update_client_ips_batch(self): + + # If the DB pool has already terminated, don't try updating + if not self.hs.get_db_pool().running: + return + def update(): to_update = self._batch_row_update self._batch_row_update = {} |