From 1163efdea955c59f110b7b809c6ff6206af8312b Mon Sep 17 00:00:00 2001 From: withoutaname Date: Fri, 11 Jul 2014 17:31:08 -0700 Subject: [PATCH] Remove $wgEnableSorbs and $wgSorbsUrl They were deprecated in version 1.17. Change-Id: I8489c0cb4a041d081283fa3551377ef81ef36549 --- RELEASE-NOTES-1.24 | 1 + includes/DefaultSettings.php | 12 ------------ includes/User.php | 8 +++----- 3 files changed, 4 insertions(+), 17 deletions(-) diff --git a/RELEASE-NOTES-1.24 b/RELEASE-NOTES-1.24 index 368654808c..7bfde7d711 100644 --- a/RELEASE-NOTES-1.24 +++ b/RELEASE-NOTES-1.24 @@ -36,6 +36,7 @@ production. * $wgFileStore was removed after having been deprecated in 1.17. Alternative configurations are $wgDeletedDirectory and $wgHashedUploadDirectory. * The deprecated $wgUseCommaCount variable has been removed. +* $wgEnableSorbs and $wgSorbsUrl have been removed. === New features in 1.24 === * Added a new hook, "WhatLinksHereProps", to allow extensions to annotate diff --git a/includes/DefaultSettings.php b/includes/DefaultSettings.php index 951e6e637e..7c81294e0a 100644 --- a/includes/DefaultSettings.php +++ b/includes/DefaultSettings.php @@ -4698,12 +4698,6 @@ $wgSummarySpamRegex = array(); */ $wgEnableDnsBlacklist = false; -/** - * @deprecated since 1.17 Use $wgEnableDnsBlacklist instead, only kept for - * backward compatibility. - */ -$wgEnableSorbs = false; - /** * List of DNS blacklists to use, if $wgEnableDnsBlacklist is true. * @@ -4729,12 +4723,6 @@ $wgEnableSorbs = false; */ $wgDnsBlacklistUrls = array( 'http.dnsbl.sorbs.net.' ); -/** - * @deprecated since 1.17 Use $wgDnsBlacklistUrls instead, only kept for - * backward compatibility. - */ -$wgSorbsUrl = array(); - /** * Proxy whitelist, list of addresses that are assumed to be non-proxy despite * what the other methods might say. diff --git a/includes/User.php b/includes/User.php index 62e35e8166..fc2b351119 100644 --- a/includes/User.php +++ b/includes/User.php @@ -1505,10 +1505,9 @@ class User implements IDBAccessObject { * @return bool True if blacklisted. */ public function isDnsBlacklisted( $ip, $checkWhitelist = false ) { - global $wgEnableSorbs, $wgEnableDnsBlacklist, - $wgSorbsUrl, $wgDnsBlacklistUrls, $wgProxyWhitelist; + global $wgEnableDnsBlacklist, $wgDnsBlacklistUrls, $wgProxyWhitelist; - if ( !$wgEnableDnsBlacklist && !$wgEnableSorbs ) { + if ( !$wgEnableDnsBlacklist ) { return false; } @@ -1516,8 +1515,7 @@ class User implements IDBAccessObject { return false; } - $urls = array_merge( $wgDnsBlacklistUrls, (array)$wgSorbsUrl ); - return $this->inDnsBlacklist( $ip, $urls ); + return $this->inDnsBlacklist( $ip, $wgDnsBlacklistUrls ); } /** -- 2.20.1