3
0
mirror of https://github.com/reality/dbot.git synced 2024-11-27 22:39:26 +01:00

lowercase all ~word related input

This commit is contained in:
reality 2013-10-20 18:57:15 +00:00
parent fd400cf3ea
commit d714b2c0be

View File

@ -187,7 +187,7 @@ var commands = function(dbot) {
}, },
'~word': function(event) { '~word': function(event) {
var word = event.params[1].trim(); var word = event.params[1].trim().toLowerCase();
this.api.getTrackedWord(word, function(tWord) { this.api.getTrackedWord(word, function(tWord) {
if(tWord) { if(tWord) {
event.reply(dbot.t('sstats_word', { event.reply(dbot.t('sstats_word', {
@ -205,7 +205,7 @@ var commands = function(dbot) {
// merge to some raw highscore thing // merge to some raw highscore thing
'~wordusers': function(event) { '~wordusers': function(event) {
var word = event.params[1].trim(); var word = event.params[1].trim().toLowerCase();
this.api.getTrackedWord(word, function(tWord) { this.api.getTrackedWord(word, function(tWord) {
if(tWord) { if(tWord) {
var pCounts = _.chain(tWord.users) var pCounts = _.chain(tWord.users)