Fix $mybool |=... which is binary op, not boolean op
# Fix $mybool |=... which is binary op, not boolean op This fixes PhanTypeInvalidLeftOperandOfBitwiseOp. Replace $var |= ... with $var = ... || $var . Add cast before ... when needed (@include does not always return bool). |= always evaluates expression, there for || $var, not $var ||
This commit is contained in:
parent
81d9e8aa01
commit
b6ac5dcf76
1 changed files with 1 additions and 1 deletions
|
|
@ -1548,7 +1548,7 @@ class Asset extends CommonObject
|
|||
$dir = dol_buildpath($reldir."core/modules/asset/");
|
||||
|
||||
// Load file with numbering class (if found)
|
||||
$mybool = $mybool || (bool) @include_once $dir.$file;
|
||||
$mybool = ((bool) @include_once $dir.$file) || $mybool;
|
||||
}
|
||||
|
||||
if ($mybool === false) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue