spl_autoload_unregister

The timeline below displays how wordpress function spl_autoload_unregister has changed across different WordPress versions. If a version is not listed, refer to the next available version below.

WordPress Version: 4.9

/**
 * Unregisters an autoloader function.
 *
 * @since 4.6.0
 *
 * @param callable $function The function to unregister.
 * @return bool True if the function was unregistered, false if it could not be.
 */
function spl_autoload_unregister($function)
{
    global $_wp_spl_autoloaders;
    foreach ($_wp_spl_autoloaders as &$autoloader) {
        if ($autoloader === $function) {
            unset($autoloader);
            return true;
        }
    }
    return false;
}