jenkins-bot has submitted this change and it was merged.

Change subject: Add an extra paranoid check to blacklisting of WAP devices from 
HTTPS
......................................................................


Add an extra paranoid check to blacklisting of WAP devices from HTTPS

Change-Id: Ida98aa8e886d3e1cca7f57897435b43dde5defc1
---
M includes/MobileFrontend.hooks.php
1 file changed, 2 insertions(+), 1 deletion(-)

Approvals:
  awjrichards: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/includes/MobileFrontend.hooks.php 
b/includes/MobileFrontend.hooks.php
index e9e1276..a67c9ae 100644
--- a/includes/MobileFrontend.hooks.php
+++ b/includes/MobileFrontend.hooks.php
@@ -624,7 +624,8 @@
         */
        public static function onUserRequiresHTTPS( $user, &$https ) {
                // WAP phones allegedly can't handle HTTPS, don't redirect them 
there
-               if ( MobileContext::singleton()->getDevice()->format() === 
'wml' ) {
+               $context = MobileContext::singleton();
+               if ( $context->shouldDisplayMobileView() && 
$context->getDevice()->format() === 'wml' ) {
                        $https = false;
                        return false; // Stop further hook processing
                }

-- 
To view, visit https://gerrit.wikimedia.org/r/80410
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ida98aa8e886d3e1cca7f57897435b43dde5defc1
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MobileFrontend
Gerrit-Branch: master
Gerrit-Owner: MaxSem <[email protected]>
Gerrit-Reviewer: MaxSem <[email protected]>
Gerrit-Reviewer: awjrichards <[email protected]>
Gerrit-Reviewer: jenkins-bot

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to