summaryrefslogtreecommitdiffstats
path: root/users
diff options
context:
space:
mode:
Diffstat (limited to 'users')
-rw-r--r--users/models/identity.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/users/models/identity.py b/users/models/identity.py
index c26762d..510b947 100644
--- a/users/models/identity.py
+++ b/users/models/identity.py
@@ -327,6 +327,10 @@ class Identity(StatorModel):
)
except httpx.RequestError:
return False
+ if response.status_code == 410:
+ # Their account got deleted, so let's do the same.
+ await Identity.objects.filter(pk=self.pk).adelete()
+ return False
if response.status_code >= 400:
return False
document = canonicalise(response.json(), include_security=True)