mirror of
https://github.com/moodle/moodle.git
synced 2025-01-18 22:08:20 +01:00
dc9b44f531
Unfortunately PHP does not provide any means to autoload the files that a functions is located in, even if they are in an namespace. To work around this, Composer makes use of an `autoload.files` section in the `composer.json` file. Shortly after the Composer autoloader is registered with the `spl_autoload_register` call it also includes any files listed in this section. Moodle does not do this and really we should be doing so. This change adds a section to the autoloader registration method which loads all of the files defined in any third-party library included in our `lib` directory which contains any `composer.json` file with such a stanza.