From 9e7693c749a90646052c82a660845314226446c3 Mon Sep 17 00:00:00 2001 From: Chad Horohoe Date: Fri, 23 Aug 2013 12:34:06 -0700 Subject: [PATCH] Only show prefershttps if IP can use HTTPS Change-Id: I7493a329d35fad3f17aac2df935f4f9306828884 --- includes/Preferences.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/Preferences.php b/includes/Preferences.php index 9791d8bdd3..4d034fa05a 100644 --- a/includes/Preferences.php +++ b/includes/Preferences.php @@ -315,7 +315,7 @@ class Preferences { ); } // Only show preferhttps if secure login is turned on - if ( $wgSecureLogin ) { + if ( $wgSecureLogin && wfCanIPUseHTTPS( $context->getRequest()->getIP() ) ) { $defaultPreferences['prefershttps'] = array( 'type' => 'toggle', 'label-message' => 'tog-prefershttps', -- 2.20.1