Permalink
Browse files

Update SnotBot

Fix AfDBot's high run frequency causing erroneous taggings.
Make RfPPBot recognize the AIV parameter.
  • Loading branch information...
cyberpower678 committed Dec 30, 2013
1 parent a061055 commit 44108a2b47b73ed27adf1214deddbad7826b9e63
Showing with 4 additions and 4 deletions.
  1. +1 −1 SnotBot/afdbot.php
  2. +3 −3 SnotBot/rfppbot.php
View
@@ -14,7 +14,7 @@
$lastredlinked = array(); //the redlinked AfD templates which were found in the last run, only display if they were found in 2 consecutive runs
$afdscores = array(); //{"AfD page title":float score} - Score for how urgently an afd needs attention
$afdstats = array(); //{"AfD page title":[delete,keep,merge,redirect,speedykeep,speedydelete,other,creationdate,closingdate]}
$frequency = 1; //in minutes, how often to run
$frequency = 15; //in minutes, how often to run
$cyclereset = (int)(240/$frequency);//cycle resets every 4 hours, for 6 hours make it 360/frequency, for 12 hours make it 720/frequency, for 24 hours make it 1440/frequency
$cyclecounter = 0;
$voteregex = '/\'{3}?.*?\'{3}?.*?(?:(?:\[\[User.*?\]\].*?\(UTC\))|(?:\{\{unsigned.*?\}\})|(?:<!--\s*Template:Unsigned\s*-->))/i';
View
@@ -81,7 +81,7 @@
}
continue;
}
if( in_array( $code, array( "d", "deny", "nea", "nact", "np", "npre", "nhr", "nhrt", "dr", "disp", "ut", "usta", "b", "bloc", "tb", "tabl", "notd", "no", "rate", "her" ) ) ) {
if( in_array( $code, array( "aiv", "d", "deny", "nea", "nact", "np", "npre", "nhr", "nhrt", "dr", "disp", "ut", "usta", "b", "bloc", "tb", "tabl", "notd", "no", "rate", "her" ) ) ) {
echo getFullPageTitle( $req ).": Declined ".timeSinceLastEdit( $req )." minutes ago\n";
if( timeSinceLastEdit( $req ) > $ARCHIVE_DENIED ) $tobearchived[] = trim( $req, "\n" )."\n\n";
continue;
@@ -153,7 +153,7 @@
continue;
}
}
if( in_array( $code, array( "d", "deny", "nea", "nact", "np", "npre", "nhr", "nhrt", "dr", "disp", "ut", "usta", "b", "bloc", "tb", "tabl", "notd", "no", "rate", "her" ) ) ) {
if( in_array( $code, array( "aiv", "d", "deny", "nea", "nact", "np", "npre", "nhr", "nhrt", "dr", "disp", "ut", "usta", "b", "bloc", "tb", "tabl", "notd", "no", "rate", "her" ) ) ) {
echo getFullPageTitle( $req ).": Declined ".timeSinceLastEdit( $req )." minutes ago\n";
if( timeSinceLastEdit( $req ) > $ARCHIVE_DENIED ) $tobearchived[] = trim( $req, "\n" )."\n\n";
continue;
@@ -212,7 +212,7 @@
if( timeSinceLastEdit( $req ) > $ARCHIVE_TIMEOUT ) $tobearchived[] = trim( $req, "\n" )."\n\n";
continue;
}
if( in_array( $code, array( "d", "deny", "nea", "nact", "np", "npre", "nhr", "nhrt", "dr", "disp", "ut", "usta", "b", "bloc", "tb", "tabl", "notd", "no", "rate", "her" ) ) ) {
if( in_array( $code, array( "aiv", "d", "deny", "nea", "nact", "np", "npre", "nhr", "nhrt", "dr", "disp", "ut", "usta", "b", "bloc", "tb", "tabl", "notd", "no", "rate", "her" ) ) ) {
echo getFullPageTitle( $req ).": Declined ".timeSinceLastEdit( $req )." minutes ago\n";
if( timeSinceLastEdit( $req ) > $ARCHIVE_DENIED ) $tobearchived[] = trim( $req, "\n" )."\n\n";
continue;

0 comments on commit 44108a2

Please sign in to comment.