From 6aa4166b7ef5021c6e6d95748a37e9541bd984d5 Mon Sep 17 00:00:00 2001 From: kishor <44048735+kish0808@users.noreply.github.com> Date: Wed, 16 Sep 2020 05:42:43 +0530 Subject: [PATCH] Issue-256: Fix PHP 7.3 compatibility issues update zend.ze1_compatibility_mode mode (#267) --- library/HTMLPurifier.autoload-legacy.php | 2 -- library/HTMLPurifier.autoload.php | 1 + 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/library/HTMLPurifier.autoload-legacy.php b/library/HTMLPurifier.autoload-legacy.php index 7766b203..0a17ee4a 100644 --- a/library/HTMLPurifier.autoload-legacy.php +++ b/library/HTMLPurifier.autoload-legacy.php @@ -4,13 +4,11 @@ * @file * Legacy autoloader for systems lacking spl_autoload_register * - * Must be separate to prevent deprecation warning on PHP 7.2 */ spl_autoload_register(function($class) { return HTMLPurifier_Bootstrap::autoload($class); -} }); // vim: et sw=4 sts=4 diff --git a/library/HTMLPurifier.autoload.php b/library/HTMLPurifier.autoload.php index 9d8d2992..7a691132 100644 --- a/library/HTMLPurifier.autoload.php +++ b/library/HTMLPurifier.autoload.php @@ -17,6 +17,7 @@ if (function_exists('spl_autoload_register') && function_exists('spl_autoload_un require dirname(__FILE__) . '/HTMLPurifier.autoload-legacy.php'; } +// phpcs:ignore PHPCompatibility.IniDirectives.RemovedIniDirectives.zend_ze1_compatibility_modeRemoved if (ini_get('zend.ze1_compatibility_mode')) { trigger_error("HTML Purifier is not compatible with zend.ze1_compatibility_mode; please turn it off", E_USER_ERROR); }