Skip to content

Node.js based forum software built for the modern web

fix(activitypub): catch no-user error in prune and add to missing set

Julian Lam4119b2dc6b14
diff --git a/src/activitypub/actors.js b/src/activitypub/actors.js
index cfea26d503..c77b2f8193 100644
--- a/src/activitypub/actors.js
+++ b/src/activitypub/actors.js
@@ -660,9 +660,10 @@ Actors.prune = async () => {
await user.deleteAccount(uid);
deletionCount += 1;
} catch (err) {
- winston.error(`Failed to delete user with uid ${uid}: ${err.stack}`);
if (err.message === '[[error:no-user]]') {
missing.add(uid);
+ } else {
+ winston.error(`Failed to delete user with uid ${uid}: ${err.stack}`);
}
}
} else {