mirror of
https://github.com/reality/dbot.git
synced 2024-12-24 03:33:07 +01:00
rookie mistake
This commit is contained in:
parent
f4a203e416
commit
badf17b0ec
@ -83,8 +83,9 @@ var warning = function(dbot) {
|
||||
var sTimes = _.keys(warns).sort(function(a, b) {
|
||||
return parseInt(a) - parseInt(b);
|
||||
});
|
||||
event.reply(_.keys(sTimes));
|
||||
|
||||
if(index < sTimes.length && index > 0) {
|
||||
if(index <= sTimes.length && index >= 0) {
|
||||
this.db.del('notifies', warns[sTimes[index]], function(err) {
|
||||
event.reply(dbot.t('warning_removed'));
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user