move configure webadmin and status out of setup logic

This commit is contained in:
Girish Ramakrishnan
2018-11-11 09:29:11 -08:00
parent b640a053e3
commit aae259479f
5 changed files with 113 additions and 103 deletions
+1 -10
View File
@@ -5,8 +5,7 @@ exports = module.exports = {
setupTokenAuth: setupTokenAuth,
provision: provision,
activate: activate,
restore: restore,
getStatus: getStatus,
restore: restore
};
var assert = require('assert'),
@@ -94,14 +93,6 @@ function provision(req, res, next) {
});
}
function getStatus(req, res, next) {
setup.getStatus(function (error, status) {
if (error) return next(new HttpError(500, error));
next(new HttpSuccess(200, status));
});
}
function activate(req, res, next) {
assert.strictEqual(typeof req.body, 'object');