var _ = require('underscore')._; var commands = function(dbot) { var quotes = dbot.db.quoteArrs; var commands = { // Alternative syntax to ~q '~': function(event) { commands['~q'].bind(this)(event); }, '~rmstatus': function(event) { var rmCacheCount = this.rmCache.length; if(rmCacheCount < dbot.config.quotes.rmLimit) { event.reply(dbot.t('quote_cache_auto_remove', { 'count': rmCacheCount })); } else { event.reply(dbot.t('quote_cache_manual_remove', { 'count': rmCacheCount })); } }, '~rmconfirm': function(event) { var rmCacheCount = this.rmCache.length; this.rmCache.length = 0; event.reply(dbot.t('quote_cache_cleared', { 'count': rmCacheCount })); }, '~rmdeny': function(event) { var rmCache = this.rmCache; var rmCacheCount = rmCache.length; for(var i=0;i