forked from FoundKeyGang/FoundKey
Revert "send reject follow if federateBlocks is false"
This reverts commit 9c9b5bb44c
.
This commit is contained in:
parent
a499c364d6
commit
6793d6accf
1 changed files with 3 additions and 9 deletions
|
@ -11,7 +11,6 @@ import { Blockings, Users, FollowRequests, Followings, UserListJoinings, UserLis
|
|||
import { perUserFollowingChart } from '@/services/chart/index.js';
|
||||
import { genId } from '@/misc/gen-id.js';
|
||||
import { getActiveWebhooks } from '@/misc/webhook-cache.js';
|
||||
import { rejectFollow } from '../following/reject.js';
|
||||
|
||||
export default async function(blocker: User, blockee: User) {
|
||||
await Promise.all([
|
||||
|
@ -33,14 +32,9 @@ export default async function(blocker: User, blockee: User) {
|
|||
|
||||
await Blockings.insert(blocking);
|
||||
|
||||
if (Users.isLocalUser(blocker) && Users.isRemoteUser(blockee)) {
|
||||
if (blocker.federateBlocks) {
|
||||
const content = renderActivity(renderBlock(blocking));
|
||||
deliver(blocker, content, blockee.inbox);
|
||||
} else {
|
||||
// Send a Reject Follow activity to the user being blocked to prevent them from reading follower-only posts.
|
||||
rejectFollow(blocker, blockee);
|
||||
}
|
||||
if (Users.isLocalUser(blocker) && Users.isRemoteUser(blockee) && blocker.federateBlocks) {
|
||||
const content = renderActivity(renderBlock(blocking));
|
||||
deliver(blocker, content, blockee.inbox);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue