3
0
mirror of https://github.com/reality/dbot.git synced 2024-12-24 19:52:36 +01:00

Quotes rm stuff no longer uses timers.js [#170]

This commit is contained in:
reality 2013-01-27 20:33:27 +00:00
parent d3c3c2a5c1
commit aeea3fc269

View File

@ -44,7 +44,7 @@ var quotes = function(dbot) {
'resetRemoveTimer': function(event, key, quote) {
this.rmAllowed = false;
dbot.timers.addOnceTimer(5000, function() {
setTimeout(5000, function() {
this.rmAllowed = true;
});
@ -52,10 +52,10 @@ var quotes = function(dbot) {
'key': key,
'quote': quote
});
dbot.timers.clearTimeout(this.rmTimer);
clearTimeout(this.rmTimer);
if(this.rmCache.length < dbot.config.quotes.rmLimit) {
this.rmTimer = dbot.timers.addOnceTimer(600000, function() {
this.rmTimer = setTimeout(600000, function() {
this.rmCache.length = 0; // lol what
}.bind(this));
} else {