r114302 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r114301‎ | r114302 | r114303 >
Date:19:59, 20 March 2012
Author:preilly
Status:ok
Tags:
Comment:
fix string comparison
Modified paths:
  • /trunk/extensions/ZeroRatedMobileAccess/ZeroRatedMobileAccess.body.php (modified) (history)

Diff [purge]

Index: trunk/extensions/ZeroRatedMobileAccess/ZeroRatedMobileAccess.body.php
@@ -158,7 +158,7 @@
159159 }
160160 if ( self::$isMainPage ) {
161161 $redirect = SpecialPage::getTitleFor( 'ZeroRatedMobileAccess' )->getLocalUrl();
162 - if ( stristr( self::$carrier, 'DIGI' ) !== FALSE ) {
 162+ if ( isset( self::$carrier['name'] ) && stristr( self::$carrier['name'], 'DIGI' ) !== FALSE ) {
163163 $redirect = 'http://en.zero.wikipedia.org/wiki/Special:ZeroRatedMobileAccess';
164164 }
165165 $wgRequest->response()->header( 'Location: ' . $redirect );

Status & tagging log