Skip to content

Commit fd0d9ac

Browse files
authored
Bug: Call to function is_array() with string (#5096)
1 parent 81786ed commit fd0d9ac

File tree

2 files changed

+1
-7
lines changed

2 files changed

+1
-7
lines changed

.phpstan.dist.baseline.neon

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2334,12 +2334,6 @@ parameters:
23342334
count: 1
23352335
path: app/code/core/Mage/Index/Model/Lock.php
23362336

2337-
-
2338-
rawMessage: 'Call to function is_array() with '''' will always evaluate to false.'
2339-
identifier: function.impossibleType
2340-
count: 1
2341-
path: app/code/core/Mage/Index/Model/Resource/Event.php
2342-
23432337
-
23442338
rawMessage: 'Parameter #1 $adapter of method Varien_Db_Adapter_Interface::setCacheAdapter() expects Zend_Cache_Backend_Interface, Zend_Cache_Core given.'
23452339
identifier: argument.type

app/code/core/Mage/Index/Model/Resource/Event.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ public function updateProcessEvents($process, $status = Mage_Index_Model_Process
9999
$whereCondition = ['process_id = ?' => $process->getId()];
100100
} elseif (is_array($process) && !empty($process)) {
101101
$whereCondition = ['process_id IN (?)' => $process];
102-
} elseif (!is_array($whereCondition)) {
102+
} elseif (!empty($process)) {
103103
$whereCondition = ['process_id = ?' => $process];
104104
}
105105

0 commit comments

Comments
 (0)