From 44b88f180bc9ec692885e7db08757a43b3e2df79 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Fri, 2 Aug 2019 09:46:48 +0200 Subject: Fix broken follow notification --- server/models/account/account.ts | 2 ++ 1 file changed, 2 insertions(+) (limited to 'server/models/account') diff --git a/server/models/account/account.ts b/server/models/account/account.ts index 28014946f..4dc412301 100644 --- a/server/models/account/account.ts +++ b/server/models/account/account.ts @@ -30,6 +30,7 @@ import { CONSTRAINTS_FIELDS, WEBSERVER } from '../../initializers/constants' import { FindOptions, IncludeOptions, Op, Transaction, WhereOptions } from 'sequelize' import { AccountBlocklistModel } from './account-blocklist' import { ServerBlocklistModel } from '../server/server-blocklist' +import { ActorFollowModel } from '../activitypub/actor-follow' export enum ScopeNames { SUMMARY = 'SUMMARY' @@ -220,6 +221,7 @@ export class AccountModel extends Model { instance.Actor = await instance.$get('Actor', { transaction: options.transaction }) as ActorModel } + await ActorFollowModel.removeFollowsOf(instance.Actor.id, options.transaction) if (instance.isOwned()) { return sendDeleteActor(instance.Actor, options.transaction) } -- cgit v1.2.3