summaryrefslogtreecommitdiff
path: root/src/static/js/pluginfw/installer.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/static/js/pluginfw/installer.js')
-rw-r--r--src/static/js/pluginfw/installer.js10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/static/js/pluginfw/installer.js b/src/static/js/pluginfw/installer.js
index 1bb8db9e..e7c6fb80 100644
--- a/src/static/js/pluginfw/installer.js
+++ b/src/static/js/pluginfw/installer.js
@@ -3,7 +3,7 @@ var hooks = require("ep_etherpad-lite/static/js/pluginfw/hooks");
var npm = require("npm");
var registry = require("npm/lib/utils/npm-registry-client/index.js");
-var withNpm = function (npmfn, cb) {
+var withNpm = function (npmfn, final, cb) {
npm.load({}, function (er) {
if (er) return cb({progress:1, error:er});
npm.on("log", function (message) {
@@ -15,6 +15,7 @@ var withNpm = function (npmfn, cb) {
data.progress = 1;
data.message = "Done.";
cb(data);
+ final();
});
});
}
@@ -36,6 +37,9 @@ exports.uninstall = function(plugin_name, cb) {
});
});
},
+ function () {
+ hooks.aCallAll("restartServer", {}, function () {});
+ },
cb
);
};
@@ -51,6 +55,9 @@ exports.install = function(plugin_name, cb) {
});
});
},
+ function () {
+ hooks.aCallAll("restartServer", {}, function () {});
+ },
cb
);
};
@@ -93,6 +100,7 @@ exports.search = function(query, cache, cb) {
}
);
},
+ function () { },
cb
);
};