summary refs log tree commit diff
path: root/synapse/handlers/device.py
diff options
context:
space:
mode:
authorRichard van der Hoff <1389908+richvdh@users.noreply.github.com>2018-04-04 10:45:22 +0100
committerGitHub <noreply@github.com>2018-04-04 10:45:22 +0100
commit725a72ec5a6b9fb8dd6e46c63566086923c12029 (patch)
treeaba825f9077fd1d945d7f5b3381e9d54cb5203b5 /synapse/handlers/device.py
parentMerge pull request #3044 from matrix-org/michaelk/performance_stats (diff)
parentreplace old style error catching with 'as' keyword (diff)
downloadsynapse-725a72ec5a6b9fb8dd6e46c63566086923c12029.tar.xz
Merge pull request #3000 from NotAFile/change-except-style
Replace old style error catching with 'as' keyword
Diffstat (limited to 'synapse/handlers/device.py')
-rw-r--r--synapse/handlers/device.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/synapse/handlers/device.py b/synapse/handlers/device.py
index 40f3d24678..f7457a7082 100644
--- a/synapse/handlers/device.py
+++ b/synapse/handlers/device.py
@@ -155,7 +155,7 @@ class DeviceHandler(BaseHandler):
 
         try:
             yield self.store.delete_device(user_id, device_id)
-        except errors.StoreError, e:
+        except errors.StoreError as e:
             if e.code == 404:
                 # no match
                 pass
@@ -204,7 +204,7 @@ class DeviceHandler(BaseHandler):
 
         try:
             yield self.store.delete_devices(user_id, device_ids)
-        except errors.StoreError, e:
+        except errors.StoreError as e:
             if e.code == 404:
                 # no match
                 pass
@@ -243,7 +243,7 @@ class DeviceHandler(BaseHandler):
                 new_display_name=content.get("display_name")
             )
             yield self.notify_device_update(user_id, [device_id])
-        except errors.StoreError, e:
+        except errors.StoreError as e:
             if e.code == 404:
                 raise errors.NotFoundError()
             else: