mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/SpamBlacklist
synced 2024-11-23 14:46:48 +00:00
Merge "Add grepability comments"
This commit is contained in:
commit
90cbe93161
|
@ -167,6 +167,9 @@ abstract class BaseBlacklist {
|
|||
if ( $title->inNamespace( NS_MEDIAWIKI ) ) {
|
||||
$sources = [];
|
||||
foreach ( self::$blacklistTypes as $type => $class ) {
|
||||
// For the built in types, this results in the use of:
|
||||
// spam-blacklist, spam-whitelist
|
||||
// email-blacklist, email-whitelist
|
||||
$type = ucfirst( $type );
|
||||
$sources[] = "$type-blacklist";
|
||||
$sources[] = "$type-whitelist";
|
||||
|
@ -190,11 +193,9 @@ abstract class BaseBlacklist {
|
|||
foreach ( $files as $fileName ) {
|
||||
$matches = [];
|
||||
if ( preg_match( '/^DB: (\w*) (.*)$/', $fileName, $matches ) ) {
|
||||
if ( $wgDBname === $matches[1] ) {
|
||||
if ( $matches[2] === $title->getPrefixedDbKey() ) {
|
||||
// Local DB fetch of this page...
|
||||
return true;
|
||||
}
|
||||
if ( $wgDBname === $matches[1] && $matches[2] === $title->getPrefixedDbKey() ) {
|
||||
// Local DB fetch of this page...
|
||||
return true;
|
||||
}
|
||||
} elseif ( preg_match( $thisHttpRegex, $fileName ) ) {
|
||||
// Raw view of this page
|
||||
|
|
Loading…
Reference in a new issue