summary refs log tree commit diff
path: root/synapse/storage/engines/postgres.py
diff options
context:
space:
mode:
Diffstat (limited to 'synapse/storage/engines/postgres.py')
-rw-r--r--synapse/storage/engines/postgres.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/synapse/storage/engines/postgres.py b/synapse/storage/engines/postgres.py
index 9910de5dc2..457c1f70a5 100644
--- a/synapse/storage/engines/postgres.py
+++ b/synapse/storage/engines/postgres.py
@@ -37,7 +37,7 @@ class PostgresEngine(object):
 
     def is_deadlock(self, error):
         if isinstance(error, self.module.DatabaseError):
-            return error.pgcode == "40P01"
+            return error.pgcode in ["40001", "40P01"]
         return False
 
     def load_unicode(self, v):