darylldoyle / svg-sanitizer

A PHP SVG/XML Sanitizer
GNU General Public License v2.0
454 stars 67 forks source link

libxml_disable_entity_loader is deprecated #66

Closed letharion closed 2 years ago

letharion commented 2 years ago

I was testing out my project on PHP 8 and got a warning about libxml_disable_entity_loader being deprecated:

https://www.php.net/manual/en/function.libxml-disable-entity-loader.php says:

Warning This function has been DEPRECATED as of PHP 8.0.0. Relying on this function is highly discouraged.

I've only taken a cursory glance at it, but it seems like the solution would be to pass an empty function or some other no-op into https://www.php.net/manual/en/function.libxml-set-external-entity-loader.php instead.

letharion commented 2 years ago

Nevermind, I see the code already has a solution.