Fix PHP 8.x Fatal: array_merge(): Argument #2 must be of type array, null given

This commit is contained in:
ralf 2022-10-17 15:58:59 +02:00
parent 9cb30f59db
commit fc716d0e6e

View File

@ -3189,7 +3189,7 @@ class Mail
//error_log(__METHOD__.__LINE__.array2string($autoFolderObjects)); //error_log(__METHOD__.__LINE__.array2string($autoFolderObjects));
// avoid calling sortByAutoFolder as it is not regarding subfolders // avoid calling sortByAutoFolder as it is not regarding subfolders
$autoFolderObjectsTmp = $autoFolderObjects; $autoFolderObjectsTmp = $autoFolderObjects;
unset($autoFolderObjects); $autoFolderObjects = [];
uasort($autoFolderObjectsTmp, array($this,'sortByMailbox')); uasort($autoFolderObjectsTmp, array($this,'sortByMailbox'));
foreach($autoFoldersTmp as $afk=>$aF) foreach($autoFoldersTmp as $afk=>$aF)
{ {