TryGhost/Ghost — pull request #1830 by schneidmaster (2014-01-03 17:07:44+00:00)
Title: Added friendly handling/error message for nonexistent plugin

Fixes #1829

* Added try-catch block in `core/server/plugins/loader.js` to catch and reject with an error when getPluginByName fails (meaning require(getPluginRelativePath(name)) failed, meaning the plugin directory doesn't exist). Error message as follows:

> Error loading plugin named \; plugin directory (/content/plugins/\) does not exist."

* Added .otherwise blocks with error logs to `core/server/plugins/index.js` to catch the new rejections and log error message to console