Improves plugin:refresh error handling

This commit is contained in:
Clark Burns 2015-11-09 15:36:58 -08:00
parent 73ed24c4c1
commit 898266f26a

View File

@ -38,6 +38,9 @@ class PluginRefresh extends Command
{
$pluginName = $this->argument('name');
$pluginName = PluginManager::instance()->normalizeIdentifier($pluginName);
if (!PluginManager::instance()->exists($pluginName)) {
throw new \InvalidArgumentException(sprintf('Plugin "%s" not found.', $pluginName));
}
$manager = UpdateManager::instance()->resetNotes();