This commit is contained in:
Yuri Kuznetsov
2020-07-22 18:25:56 +03:00
parent f68c594a7e
commit 2398ef7efe
+2 -3
View File
@@ -168,9 +168,8 @@ class Stream
}
}
protected function getAutofollowUserIdList(Entity $entity, array $ignoreList = [])
protected function getAutofollowUserIdList(string $entityType, array $ignoreList = [])
{
$entityType = $entity->getEntityType();
$pdo = $this->entityManager->getPDO();
$userIdList = [];
@@ -261,7 +260,7 @@ class Stream
$entity->set('isFollowed', true);
}
$autofollowUserIdList = $this->getAutofollowUserIdList($entity, $userIdList);
$autofollowUserIdList = $this->getAutofollowUserIdList($entity->getEntityType(), $userIdList);
foreach ($autofollowUserIdList as $i => $userId) {
if (in_array($userId, $userIdList)) {
unset($autofollowUserIdList[$i]);