Closed blackstar0169 closed 2 years ago
Ok, I think it makes sense to do a new major version of sabre/xml that removes libxml_disable_entity_loader()
, and has PHP 8 as a minimum version.
On this link https://php.watch/versions/8.0/libxml_disable_entity_loader-deprecation the author said that it is safe to do this for backward compatibility :
- libxml_disable_entity_loader(true);
+ if (\PHP_VERSION_ID < 80000) {
+ libxml_disable_entity_loader(true);
+ }
Or this in case you want to rely on libxml version :
- libxml_disable_entity_loader(true);
+ if (\LIBXML_VERSION < 20900) {
+ libxml_disable_entity_loader(true);
+ }
I think this could avoid making a major version, but my knowledge on XML parsing is limited, so I don't know what consequences those changes may have in this library.
That sounds like a better idea =)
IMO this was fixed in commit https://github.com/sabre-io/xml/pull/190/commits/73040eda220955a9ab3721c25483da1192c36242
And then the logic was improved in #204
Please feel free to ping here if it is not working.
I got this error when I send a PROPFIND request.
This function is deprecated as of PHP 8.0 https://www.php.net/manual/en/function.libxml-disable-entity-loader.php
My request timeline :
Thanks for sharing this nice library !