Warning (2): Trying to access array offset on value of type null [APP/Controller/ContentsController.php, line 376]
Warning (2): Trying to access array offset on value of type null [APP/Controller/ContentsController.php, line 377]
Warning (2): Trying to access array offset on value of type null [APP/Controller/ContentsController.php, line 377]
Warning (2): Trying to access array offset on value of type null [APP/Controller/AppController.php, line 78]
Warning (512): Unable to emit headers. Headers sent in file=/home/walmsley/public_html/vendor/cakephp/cakephp/src/Error/Debugger.php line=988 [CORE/src/Http/ResponseEmitter.php, line 71]
Warning (2): Cannot modify header information - headers already sent by (output started at /home/walmsley/public_html/vendor/cakephp/cakephp/src/Error/Debugger.php:988) [CORE/src/Http/ResponseEmitter.php, line 168]
Warning (2): Cannot modify header information - headers already sent by (output started at /home/walmsley/public_html/vendor/cakephp/cakephp/src/Error/Debugger.php:988) [CORE/src/Http/ResponseEmitter.php, line 197]
Error: count(): Argument #1 ($value) must be of type Countable|array, null given

count(): Argument #1 ($value) must be of type Countable|array, null given 📋

TypeError
Toggle Vendor Stack Frames
    public function isAuthorizedForPage($data) {
        //$this->debug($data);
        $groupIds = array();
        $userGroupId $this->UserAuth->getGroupId();
        if (count($data['content_groups']) > 0) {
            foreach ($data['content_groups'] as $value) {
                $groupIds[] = $value['group_id'];
            }
            if (in_array($userGroupId$groupIds)) {
Error in: ROOT/src/Controller/AppController.php, line 78

If you want to customize this error message, create templates/Error/error500.php