Merge pull request #19504 from fappels/14_fix_fatal_eval
FIX 14.0.4 fatal error on cron list.
This commit is contained in:
commit
c6fb026b75
@ -8082,7 +8082,7 @@ function verifCond($strRights)
|
|||||||
|
|
||||||
//print $strRights."<br>\n";
|
//print $strRights."<br>\n";
|
||||||
$rights = true;
|
$rights = true;
|
||||||
if ($strRights !== '') {
|
if (isset($strRights) && $strRights !== '') {
|
||||||
$str = 'if(!('.$strRights.')) { $rights = false; }';
|
$str = 'if(!('.$strRights.')) { $rights = false; }';
|
||||||
dol_eval($str); // The dol_eval must contains all the global $xxx used into a condition
|
dol_eval($str); // The dol_eval must contains all the global $xxx used into a condition
|
||||||
}
|
}
|
||||||
|
|||||||
@ -478,7 +478,7 @@ if ($num > 0) {
|
|||||||
if (empty($obj)) {
|
if (empty($obj)) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if (!verifCond($obj->test)) {
|
if (isset($obj->test) && !verifCond($obj->test)) {
|
||||||
continue; // Discard line with test = false
|
continue; // Discard line with test = false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user