Update FixDuplicateProfiles command

This commit is contained in:
Daniel Supernault 2023-01-21 08:33:58 -07:00
parent 39d683b9fe
commit 443acb8227
No known key found for this signature in database
GPG key ID: 0DEF1C662C9033F7

View file

@ -155,8 +155,8 @@ class FixDuplicateProfiles extends Command
protected function checkFollowers($id, $oid) protected function checkFollowers($id, $oid)
{ {
Follower::whereProfileId($oid)->update(['profile_id' => $id]); Follower::whereProfileId($oid)->where('profile_id', '!=', $id)->update(['profile_id' => $id]);
Follower::whereFollowingId($oid)->update(['following_id' => $id]); Follower::whereFollowingId($oid)->where('following_id', '!=', $id)->update(['following_id' => $id]);
} }
protected function checkHashtagFollow($id, $oid) protected function checkHashtagFollow($id, $oid)