From 756bad3f6c50b016a62de360dc42f46f351e253c Mon Sep 17 00:00:00 2001 From: Aaron Schulz Date: Fri, 16 May 2008 20:06:19 +0000 Subject: [PATCH] Don't let underscore differences cause read whitelist matches to fail (bug 11668) --- includes/Title.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/includes/Title.php b/includes/Title.php index 28ee6fbdef..89e20b0f95 100644 --- a/includes/Title.php +++ b/includes/Title.php @@ -1445,7 +1445,9 @@ class Title { * Check for explicit whitelisting */ $name = $this->getPrefixedText(); - if( in_array( $name, $wgWhitelistRead, true ) ) + $dbName = $this->getPrefixedDBKey(); + // Check with and without underscores + if( in_array($name,$wgWhitelistRead,true) || in_array($dbName,$wgWhitelistRead,true) ) return true; /** -- 2.20.1