summaryrefslogtreecommitdiffstats
path: root/lib/plugins/plugin.js
diff options
context:
space:
mode:
Diffstat (limited to 'lib/plugins/plugin.js')
-rw-r--r--lib/plugins/plugin.js3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/plugins/plugin.js b/lib/plugins/plugin.js
index 0216a18..ae8886c 100644
--- a/lib/plugins/plugin.js
+++ b/lib/plugins/plugin.js
@@ -8,11 +8,11 @@ var gitbook = require('../gitbook');
var registry = require('./registry');
// Return true if an error is a "module not found"
+// Wait on https://github.com/substack/node-resolve/pull/81 to be merged
function isModuleNotFound(err) {
return err.message.indexOf('Cannot find module') >= 0;
}
-
function BookPlugin(book, pluginId) {
this.book = book;
this.log = this.book.log;
@@ -52,7 +52,6 @@ BookPlugin.prototype.load = function() {
that.root = path.dirname(res);
that.packageInfos = require(res);
} catch (err) {
- // Wait on https://github.com/substack/node-resolve/pull/81 to be merged
if (!isModuleNotFound(err)) throw err;
that.packageInfos = undefined;