Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 10 additions & 3 deletions web/app/mu-plugins/bedrock-autoloader.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,20 @@
* Plugin Name: Bedrock Autoloader
* Plugin URI: https://github.com/roots/bedrock-autoloader
* Description: An autoloader that enables standard plugins to be required just like must-use plugins. The autoloaded plugins are included during mu-plugin loading. An asterisk (*) next to the name of the plugin designates the plugins that have been autoloaded.
* Version: 2.0.0
* Author: Roots
* Author URI: https://roots.io/
* License: MIT License
*/

namespace Roots\Bedrock;
if (is_blog_installed() && class_exists(\Roots\Bedrock\Autoloader\Autoloader::class)) {
$autoloader = new \Roots\Bedrock\Autoloader\Autoloader(WPMU_PLUGIN_DIR);

if (is_blog_installed() && class_exists(Autoloader::class)) {
new Autoloader();
foreach ($autoloader->boot() as $file) {
include_once $file;
}

$autoloader->markLoaded();

unset($autoloader, $file);
}
Loading