summaryrefslogtreecommitdiff
path: root/internal/processing/workers
diff options
context:
space:
mode:
Diffstat (limited to 'internal/processing/workers')
-rw-r--r--internal/processing/workers/fromclientapi.go4
-rw-r--r--internal/processing/workers/fromfediapi.go2
2 files changed, 4 insertions, 2 deletions
diff --git a/internal/processing/workers/fromclientapi.go b/internal/processing/workers/fromclientapi.go
index 04ad4152c..9ea37a2f2 100644
--- a/internal/processing/workers/fromclientapi.go
+++ b/internal/processing/workers/fromclientapi.go
@@ -1093,11 +1093,13 @@ func (p *clientAPI) DeleteAccountOrUser(ctx context.Context, cMsg *messages.From
p.state.Caches.Timelines.List.Delete(listID)
}
+ // Federate out a delete activity targeting account to remote servers.
if err := p.federate.DeleteAccount(ctx, cMsg.Target); err != nil {
log.Errorf(ctx, "error federating account delete: %v", err)
}
- if err := p.account.Delete(ctx, cMsg.Target, originID); err != nil {
+ // And finally, perform the actual account deletion synchronously.
+ if err := p.account.Delete(ctx, account, originID); err != nil {
log.Errorf(ctx, "error deleting account: %v", err)
}
diff --git a/internal/processing/workers/fromfediapi.go b/internal/processing/workers/fromfediapi.go
index 5dbb8ba2e..926825b69 100644
--- a/internal/processing/workers/fromfediapi.go
+++ b/internal/processing/workers/fromfediapi.go
@@ -1120,7 +1120,7 @@ func (p *fediAPI) DeleteAccount(ctx context.Context, fMsg *messages.FromFediAPI)
// Remove any entries authored by account from timelines.
p.surface.removeTimelineEntriesByAccount(account.ID)
- // First perform the actual account deletion.
+ // And finally, perform the actual account deletion synchronously.
if err := p.account.Delete(ctx, account, account.ID); err != nil {
log.Errorf(ctx, "error deleting account: %v", err)
}