Skip to content
Permalink
Browse files

Add more descriptive message for autoloader error

  • Loading branch information...
muglug committed Apr 18, 2019
1 parent d51475b commit 50035334d4cdd63ef32a64ef41b52b3c7b336cb9
Showing with 8 additions and 1 deletion.
  1. +8 −1 src/command_functions.php
@@ -87,7 +87,14 @@ function requireAutoloaders($current_dir, $has_explicit_root, $vendor_dir)
}
if ($first_autoloader === null) {
echo 'Failed to find a valid Composer ClassLoader in ' . implode(', ', $autoload_files) . "\n";
if (!$autoload_files) {
echo 'Failed to find a valid Composer autoloader' . "\n";
} else {
echo 'Failed to find a valid Composer autoloader in ' . implode(', ', $autoload_files) . "\n";
}
echo 'Please make sure you’ve run `composer install` in the current directory before using Psalm.' . "\n";
exit(1);
}

0 comments on commit 5003533

Please sign in to comment.
You can’t perform that action at this time.