Merge "Use utf8 charset for searchindex MySQL table"
[lhc/web/wiklou.git] / includes / Wiki.php
index 55805ba..0683d7c 100644 (file)
@@ -428,7 +428,8 @@ class MediaWiki {
 
                $act = $this->getAction();
 
-               $action = Action::factory( $act, $page );
+               $action = Action::factory( $act, $page, $this->context );
+
                if ( $action instanceof Action ) {
                        # Let Squid cache things if we can purge them.
                        if ( $wgUseSquid &&
@@ -508,9 +509,14 @@ class MediaWiki {
                // preference set, redirect them to HTTPS.
                if (
                        (
+                               $request->getCookie( 'forceHTTPS', '' ) ||
+                               // check for prefixed version for currently logged in users
                                $request->getCookie( 'forceHTTPS' ) ||
                                // Avoid checking the user and groups unless it's enabled.
-                               $this->context->getUser()->requiresHTTPS()
+                               (
+                                       $this->context->getUser()->isLoggedIn()
+                                       && $this->context->getUser()->requiresHTTPS()
+                               )
                        ) &&
                        $request->detectProtocol() == 'http'
                ) {