Don't incldue deleted in history
This commit is contained in:
parent
e423475195
commit
9ab51ac67f
1 changed files with 5 additions and 1 deletions
|
|
@ -13,7 +13,7 @@ class HistoryUtils
|
|||
{
|
||||
$userIds = [];
|
||||
session([RECENTLY_VIEWED => false]);
|
||||
|
||||
|
||||
if (is_array($users)) {
|
||||
foreach ($users as $user) {
|
||||
$userIds[] = $user->user_id;
|
||||
|
|
@ -96,6 +96,10 @@ class HistoryUtils
|
|||
return;
|
||||
}
|
||||
|
||||
if ($entity->is_deleted) {
|
||||
return;
|
||||
}
|
||||
|
||||
$object = static::convertToObject($entity);
|
||||
$history = Session::get(RECENTLY_VIEWED) ?: [];
|
||||
$accountHistory = isset($history[$entity->account_id]) ? $history[$entity->account_id] : [];
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue