mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-16 10:46:14 +01:00
Use console.log instead of process.stdout.write (#6123)
* Use console.log instead of process.stdout.write * Don't break the installer
This commit is contained in:
committed by
Barış Soner Uşaklı
parent
15c8693a23
commit
dbdc05404d
@@ -141,7 +141,7 @@ events.deleteAll = function (callback) {
|
||||
};
|
||||
|
||||
events.output = function () {
|
||||
process.stdout.write('\nDisplaying last ten administrative events...\n'.bold);
|
||||
console.log('\nDisplaying last ten administrative events...'.bold);
|
||||
events.getEvents(0, 9, function (err, events) {
|
||||
if (err) {
|
||||
winston.error('Error fetching events', err);
|
||||
@@ -149,7 +149,7 @@ events.output = function () {
|
||||
}
|
||||
|
||||
events.forEach(function (event) {
|
||||
process.stdout.write(' * ' + String(event.timestampISO).green + ' ' + String(event.type).yellow + (event.text ? ' ' + event.text : '') + ' (uid: '.reset + (event.uid ? event.uid : 0) + ')\n');
|
||||
console.log(' * ' + String(event.timestampISO).green + ' ' + String(event.type).yellow + (event.text ? ' ' + event.text : '') + ' (uid: '.reset + (event.uid ? event.uid : 0) + ')');
|
||||
});
|
||||
|
||||
process.exit(0);
|
||||
|
||||
Reference in New Issue
Block a user