remove redundant check

Whether the actor is suspended is already checked in the performOneActivity
function and does not need to be checked here again since the actor is still
the same as it was there.
This commit is contained in:
Johann150 2023-05-28 23:31:06 +02:00
parent 2696c34f6c
commit 89fad52272
Signed by untrusted user: Johann150
GPG key ID: 9EE6577A2A06F8F1

View file

@ -14,10 +14,6 @@ import { shouldBlockInstance } from '@/misc/should-block-instance.js';
export default async function(resolver: Resolver, actor: IRemoteUser, activity: IAnnounce, targetUri: string): Promise<void> { export default async function(resolver: Resolver, actor: IRemoteUser, activity: IAnnounce, targetUri: string): Promise<void> {
const uri = getApId(activity); const uri = getApId(activity);
if (actor.isSuspended) {
return;
}
// Cancel if the announced from host is blocked. // Cancel if the announced from host is blocked.
if (await shouldBlockInstance(extractDbHost(uri))) return; if (await shouldBlockInstance(extractDbHost(uri))) return;