mirror of
https://github.com/moodle/moodle.git
synced 2025-08-11 20:06:46 +02:00
MDL-76953 mod: deprecate libxml library method wrappers.
The `libxml_disable_entity_loader` method is deprecated since PHP8.0, which is our minimum required version so we no longer need to support calls to it using the current wrappers.
This commit is contained in:
parent
1b1a15a308
commit
436a279dec
5 changed files with 14 additions and 15 deletions
|
@ -70,13 +70,10 @@ if ($consumerkey === false) {
|
|||
}
|
||||
|
||||
// TODO MDL-46023 Replace this code with a call to the new library.
|
||||
$origentity = lti_libxml_disable_entity_loader(true);
|
||||
$xml = simplexml_load_string($rawbody);
|
||||
if (!$xml) {
|
||||
lti_libxml_disable_entity_loader($origentity);
|
||||
throw new Exception('Invalid XML content');
|
||||
}
|
||||
lti_libxml_disable_entity_loader($origentity);
|
||||
|
||||
$body = $xml->imsx_POXBody;
|
||||
foreach ($body->children() as $child) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue