mirror of
https://github.com/slawkens/myaac.git
synced 2025-04-26 17:29:21 +02:00
phpstan adjustments
This commit is contained in:
parent
6494bd2c0c
commit
54609bf90e
@ -787,7 +787,7 @@ function get_browser_languages()
|
||||
$languages = str_replace(' ', '', $languages);
|
||||
|
||||
foreach(explode(',', $languages) as $language_list)
|
||||
$ret[] .= substr($language_list, 0, 2);
|
||||
$ret[] = substr($language_list, 0, 2);
|
||||
|
||||
return $ret;
|
||||
}
|
||||
@ -1308,11 +1308,12 @@ function getCustomPage($name, &$success): string
|
||||
$tmp = $page['body'];
|
||||
|
||||
$php_errors = array();
|
||||
function error_handler($errno, $errstr) {
|
||||
$errorHandler = function ($errno, $errstr): void
|
||||
{
|
||||
global $php_errors;
|
||||
$php_errors[] = array('errno' => $errno, 'errstr' => $errstr);
|
||||
}
|
||||
set_error_handler('error_handler');
|
||||
set_error_handler($errorHandler);
|
||||
|
||||
global $config;
|
||||
if(setting('core.backward_support')) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user