Reverting r44681 "Throw in quick hack $wgRateLimitsExcludedIPs so we don't have to...
authorBrion Vibber <brion@users.mediawiki.org>
Wed, 17 Dec 2008 00:05:55 +0000 (00:05 +0000)
committerBrion Vibber <brion@users.mediawiki.org>
Wed, 17 Dec 2008 00:05:55 +0000 (00:05 +0000)
r44592 (bug 7492) seems to cover this case with an extension to autopromote settings. Future on-wiki stuff still would be nice...

includes/DefaultSettings.php
includes/User.php

index 100c50a..88dbb99 100644 (file)
@@ -3205,16 +3205,6 @@ $wgRateLimitLog = null;
  */
 $wgRateLimitsExcludedGroups = array();
 
-/**
- * Array of IPs which should never trigger the rate limiter.
- * Really this is a cruddy hack and should be replaced with
- * an "anti-block" or something which can be managed through
- * the wiki UI.
- *
- *  $wgRateLimitsExcludedIPs = array( '1.2.3.4' );
- */
-$wgRateLimitsExcludedIPs = array();
-
 /**
  * On Special:Unusedimages, consider images "used", if they are put
  * into a category. Default (false) is not to count those as used.
index bd0fe3a..85701e3 100644 (file)
@@ -1146,17 +1146,10 @@ class User {
         */
        public function isPingLimitable() {
                global $wgRateLimitsExcludedGroups;
-               global $wgRateLimitsExcludedIPs;
                if( array_intersect( $this->getEffectiveGroups(), $wgRateLimitsExcludedGroups ) ) {
                        // Deprecated, but kept for backwards-compatibility config
                        return false;
                }
-               if( in_array( wfGetIP(), $wgRateLimitsExcludedIPs ) ) {
-                       // No other good way currently to disable rate limits
-                       // for specific IPs. :P
-                       // But this is a crappy hack and should die.
-                       return false;
-               }
                return !$this->isAllowed('noratelimit');
        }