mirror of
https://git.tt-rss.org/git/tt-rss.git
synced 2025-12-13 13:15:55 +00:00
Replace '__autoload' (deprecated in PHP 7.2) with 'spl_autoload_register'.
http://php.net/manual/en/function.autoload.php http://php.net/spl_autoload_register https://wiki.php.net/rfc/deprecations_php_7_2
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
require_once "functions.php";
|
||||
|
||||
function __autoload($class) {
|
||||
spl_autoload_register(function($class) {
|
||||
$class_file = str_replace("_", "/", strtolower(basename($class)));
|
||||
|
||||
$file = dirname(__FILE__)."/../classes/$class_file.php";
|
||||
@@ -10,4 +10,4 @@
|
||||
require $file;
|
||||
}
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user