mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-07-05 11:59:48 +02:00
added restart button to ACP (!!)
This commit is contained in:
@@ -336,4 +336,12 @@ var fs = require('fs'),
|
||||
db.getFileName(callback);
|
||||
}
|
||||
};
|
||||
|
||||
Meta.restart = function() {
|
||||
if (process.send) {
|
||||
process.send('nodebb:restart');
|
||||
} else {
|
||||
winston.error('[meta.restart] Could not restart, are you sure NodeBB was started with `./nodebb start`?');
|
||||
}
|
||||
};
|
||||
}(exports));
|
||||
|
||||
@@ -31,6 +31,10 @@ SocketAdmin.before = function(socket, next) {
|
||||
});
|
||||
};
|
||||
|
||||
SocketAdmin.restart = function(socket, data, callback) {
|
||||
meta.restart();
|
||||
};
|
||||
|
||||
/* Topics */
|
||||
|
||||
SocketAdmin.topics = {};
|
||||
|
||||
Reference in New Issue
Block a user