summaryrefslogtreecommitdiffstats
path: root/php-jeremeamia-superclosure-autoload.php
diff options
context:
space:
mode:
Diffstat (limited to 'php-jeremeamia-superclosure-autoload.php')
-rw-r--r--php-jeremeamia-superclosure-autoload.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/php-jeremeamia-superclosure-autoload.php b/php-jeremeamia-superclosure-autoload.php
index 2ccdb0a..13f5b27 100644
--- a/php-jeremeamia-superclosure-autoload.php
+++ b/php-jeremeamia-superclosure-autoload.php
@@ -15,5 +15,9 @@ if (!isset($fedoraClassLoader) || !($fedoraClassLoader instanceof \Symfony\Compo
$fedoraClassLoader->addPrefix('SuperClosure\\', dirname(__DIR__));
// Dependencies
-require_once $vendorDir . '/PhpParser/autoload.php';
+if (file_exists($vendorDir . '/PhpParser2/autoload.php')) {
+ require_once $vendorDir . '/PhpParser2/autoload.php';
+} else {
+ require_once $vendorDir . '/PhpParser/autoload.php';
+}
require_once $vendorDir . '/Symfony/Polyfill/autoload.php';