Update FollowServiceWarmCache

This commit is contained in:
Daniel Supernault 2023-12-03 03:05:00 -07:00
parent 1ef885c1a1
commit fe9b4c5a37
No known key found for this signature in database
GPG Key ID: 23740873EE6F76A1
1 changed files with 1 additions and 1 deletions

View File

@ -73,7 +73,7 @@ class FollowServiceWarmCache implements ShouldQueue
if(Follower::whereProfileId($id)->orWhere('following_id', $id)->count()) {
$following = [];
$followers = [];
foreach(Follower::lazy() as $follow) {
foreach(Follower::where('following_id', $id)->orWhere('profile_id', $id)->lazyById(500) as $follow) {
if($follow->following_id != $id && $follow->profile_id != $id) {
continue;
}