forked from mirror/pixelfed
Update FollowerController
This commit is contained in:
parent
77d4e45729
commit
c248c9d737
|
@ -33,7 +33,7 @@ class FollowerController extends Controller
|
||||||
$private = (bool) $target->is_private;
|
$private = (bool) $target->is_private;
|
||||||
$isFollowing = Follower::whereProfileId($user->id)->whereFollowingId($target->id)->count();
|
$isFollowing = Follower::whereProfileId($user->id)->whereFollowingId($target->id)->count();
|
||||||
|
|
||||||
if($private == true) {
|
if($private == true && $isFollowing == 0) {
|
||||||
$follow = new FollowRequest;
|
$follow = new FollowRequest;
|
||||||
$follow->follower_id = $user->id;
|
$follow->follower_id = $user->id;
|
||||||
$follow->following_id = $target->id;
|
$follow->following_id = $target->id;
|
||||||
|
|
Loading…
Reference in New Issue