Fixed PHP 8.1: Debugger.php, htmlspecialchars(null)

PaulB

Well-known member
Affected version
2.2.8
This differs from https://xenforo.com/community/threa...-when-viewing-debug-page-with-php-8-1.200923/ but affects the same class.

Code:
An exception occurred: [ErrorException] [E_DEPRECATED] htmlspecialchars(): Passing null to parameter #1 ($string) of type string is deprecated in src/XF/Debugger.php on line 204

XF::handlePhpError()
htmlspecialchars() in src/XF/Debugger.php at line 204
XF\Debugger::getDatabaseDebugInfo() in src/XF/Debugger.php at line 124
XF\Debugger->getDebugPageHtml() in src/XF/App.php at line 2125
XF\App->finalOutputFilter() in src/XF/App.php at line 2355
XF\App->run() in src/XF.php at line 517
XF::runApp() in index.php at line 20
 
Thank you for reporting this issue, it has now been resolved. We are aiming to include any changes that have been made in a future XF release (2.2.9).

Change log:
Fix null query parameter handling on the debug page
There may be a delay before changes are rolled out to the XenForo Community.
 
Top Bottom