Running with v8.8.0 and php v8.2.x and when executing sudo -u www-data php -f cron.php I get the following error:
PHP Fatal error: Uncaught TypeError: in_array(): Argument #2 ($haystack) must be of type array, string given in /home/crmsystem/html/public/legacy/cron.php:62
Stack trace:
#0 /home/crmsystem/html/public/legacy/cron.php(62): in_array()
#1 {main}
thrown in /home/crmsystem/html/public/legacy/cron.php on line 62
were line 62 (and 63) contains:
if (!in_array($cronUser, $sugar_config['cron']['allowed_cron_users'])) {
$GLOBALS['log']->fatal("cron.php: running as $cronUser is not allowed in allowed_cron_users ".
Cron user to be used as been set to www-data in SmartCRM config. What is missing to fix this?