This commit is contained in:
reality 2013-10-22 16:48:33 +00:00
parent d044232cd0
commit 5c0a9d9300

View File

@ -13,7 +13,7 @@ var commands = function(dbot) {
'words': uStats.words, 'words': uStats.words,
'curses': uStats.curses, 'curses': uStats.curses,
'capitals': uStats.capitals, 'capitals': uStats.capitals,
'date': new Date(uStats.creation).format('dd/mm/YYYY') 'date': moment(uStats.creation).format('dd/mm/YYYY')
}); });
if(event.rChannel && _.has(uStats.channels, event.rChannel.id)) { if(event.rChannel && _.has(uStats.channels, event.rChannel.id)) {
ucStats = uStats.channels[event.rChannel.id]; ucStats = uStats.channels[event.rChannel.id];
@ -51,7 +51,7 @@ var commands = function(dbot) {
var output = dbot.t('sstats_tlines', { var output = dbot.t('sstats_tlines', {
'user': user.primaryNick, 'user': user.primaryNick,
'lines': uStats.lines, 'lines': uStats.lines,
'date': new Date(uStats.creation).format('dd/mm/YYYY') 'date': moment(uStats.creation).format('dd/mm/YYYY')
}); });
if(event.rChannel && _.has(uStats.channels, event.rChannel.id)) { if(event.rChannel && _.has(uStats.channels, event.rChannel.id)) {
output += dbot.t('sstats_uclines', { output += dbot.t('sstats_uclines', {
@ -197,7 +197,7 @@ var commands = function(dbot) {
'total': tWord.total, 'total': tWord.total,
'channels': _.keys(tWord.channels).length, 'channels': _.keys(tWord.channels).length,
'users': _.keys(tWord.users).length, 'users': _.keys(tWord.users).length,
'since': new Date(tWord.creation) 'since': moment(tWord.creation).format('dd/mm/YYYY');
})); }));
} else { } else {
event.reply(word + ' isn\'t being tracked.'); event.reply(word + ' isn\'t being tracked.');