Skip to content

Commit

Permalink
fix(core): include vendor autoload
Browse files Browse the repository at this point in the history
Signed-off-by: Stanislas <skita@teclib.com>
  • Loading branch information
stonebuzz committed Feb 3, 2020
1 parent 7193604 commit 1d27b17
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion setup.php
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,15 @@ function plugin_init_fields() {

$PLUGIN_HOOKS['csrf_compliant']['fields'] = true;


// only if Yaml is not already present
if (!class_exists('Symfony\Component\Yaml\Yaml')) {
include_once(PLUGINFIELDS_DIR . "/inc/autoload.php");
}


// manage autoload of plugin custom classes
include_once(PLUGINFIELDS_DIR . "/inc/autoload.php");
include_once(PLUGINFIELDS_DIR . "/vendor/autoload.php");
$pluginfields_autoloader = new PluginFieldsAutoloader([PLUGINFIELDS_CLASS_PATH]);
$pluginfields_autoloader->register();

Expand Down

0 comments on commit 1d27b17

Please sign in to comment.