Warning (2) : Undefined variable $mime [in /home/appsites/www/www/src/Controller/PagesController.php, line 115]
Warning (512) : Unable to emit headers. Headers sent in file=/home/appsites/www/www/vendor/cakephp/cakephp/src/Error/Renderer/HtmlErrorRenderer.php line=36 [in /home/appsites/www/www/vendor/cakephp/cakephp/src/Http/ResponseEmitter.php, line 71]
Warning (2) : Cannot modify header information - headers already sent by (output started at /home/appsites/www/www/vendor/cakephp/cakephp/src/Error/Renderer/HtmlErrorRenderer.php:36) [in /home/appsites/www/www/vendor/cakephp/cakephp/src/Http/ResponseEmitter.php, line 168]
Warning (2) : Cannot modify header information - headers already sent by (output started at /home/appsites/www/www/vendor/cakephp/cakephp/src/Error/Renderer/HtmlErrorRenderer.php:36) [in /home/appsites/www/www/vendor/cakephp/cakephp/src/Http/ResponseEmitter.php, line 197]
Error: Cake\Http\Response::withType(): Argument #1 ($contentType) must be of type string, null given, called in /home/appsites/www/www/src/Controller/PagesController.php on line 115

Cake\Http\Response::withType(): Argument #1 ($contentType) must be of type string, null given, called in /home/appsites/www/www/src/Controller/PagesController.php on line 115 📋

TypeError
Toggle Vendor Stack Frames
        if (true) {
            $streamFactory = new StreamFactory();
            return $this->response
                ->withType($mime)
                ->withBody($streamFactory->createStreamFromFile($file));
        } else {
            //show a placeholder image when the images does not exist
            //            return $this->response
Error in: ROOT/vendor/cakephp/cakephp/src/Http/Response.php, line 711

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