diff options
author | Julian Brost | 2018-01-20 19:23:34 +0100 |
---|---|---|
committer | Julian Brost | 2018-01-20 19:23:34 +0100 |
commit | afbaccea58fa2248aa4322b5c8a011af96e9203a (patch) | |
tree | d3bf531bc169a162bb224724cf0d1f8287e1f3dc /HTMLPurifier-autoload-deprecation-warning.diff | |
parent | 3b57447789329815b827c2272b0b8ea973965cc6 (diff) | |
download | aur-afbaccea58fa2248aa4322b5c8a011af96e9203a.tar.gz |
new version 2.5.0-1
Diffstat (limited to 'HTMLPurifier-autoload-deprecation-warning.diff')
-rw-r--r-- | HTMLPurifier-autoload-deprecation-warning.diff | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/HTMLPurifier-autoload-deprecation-warning.diff b/HTMLPurifier-autoload-deprecation-warning.diff new file mode 100644 index 000000000000..2062a7c92a3f --- /dev/null +++ b/HTMLPurifier-autoload-deprecation-warning.diff @@ -0,0 +1,32 @@ +--- /dev/null ++++ b/library/vendor/HTMLPurifier.autoload-legacy.php +@@ -0,0 +1,15 @@ ++<?php ++ ++/** ++ * @file ++ * Legacy autoloader for systems lacking spl_autoload_register ++ * ++ * Must be separate to prevent deprecation warning on PHP 7.2 ++ */ ++ ++function __autoload($class) ++{ ++ return HTMLPurifier_Bootstrap::autoload($class); ++} ++ ++// vim: et sw=4 sts=4 +--- a/library/vendor/HTMLPurifier.autoload.php ++++ b/library/vendor/HTMLPurifier.autoload.php +@@ -14,10 +14,7 @@ + spl_autoload_register('__autoload'); + } + } elseif (!function_exists('__autoload')) { +- function __autoload($class) +- { +- return HTMLPurifier_Bootstrap::autoload($class); +- } ++ require dirname(__FILE__) . '/HTMLPurifier.autoload-legacy.php'; + } + + if (ini_get('zend.ze1_compatibility_mode')) { |