User::saveOptions() optimization
[lhc/web/wiklou.git] / includes / cache / HTMLFileCache.php
index 055fd68..2629995 100644 (file)
@@ -94,6 +94,7 @@ class HTMLFileCache extends FileCacheBase {
                }
                if ( $wgShowIPinHeader || $wgDebugToolbar ) {
                        wfDebug( "HTML file cache skipped. Either \$wgShowIPinHeader and/or \$wgDebugToolbar on\n" );
+
                        return false;
                }
 
@@ -109,6 +110,7 @@ class HTMLFileCache extends FileCacheBase {
                        } elseif ( $query === 'maxage' || $query === 'smaxage' ) {
                                continue;
                        }
+
                        return false;
                }
                $user = $context->getUser();
@@ -116,6 +118,7 @@ class HTMLFileCache extends FileCacheBase {
                // and extensions for auto-detecting user language.
                $ulang = $context->getLanguage()->getCode();
                $clang = $wgContLang->getCode();
+
                // Check that there are no other sources of variation
                return !$user->getId() && !$user->getNewtalk() && $ulang == $clang;
        }
@@ -163,7 +166,7 @@ class HTMLFileCache extends FileCacheBase {
                        return $text;
                }
 
-               wfDebug( __METHOD__ . "()\n", false);
+               wfDebug( __METHOD__ . "()\n", false );
 
                $now = wfTimestampNow();
                if ( $this->useGzip() ) {
@@ -182,9 +185,10 @@ class HTMLFileCache extends FileCacheBase {
 
                // gzip output to buffer as needed and set headers...
                if ( $this->useGzip() ) {
-                       // @TODO: ugly wfClientAcceptsGzip() function - use context!
+                       // @todo Ugly wfClientAcceptsGzip() function - use context!
                        if ( wfClientAcceptsGzip() ) {
                                header( 'Content-Encoding: gzip' );
+
                                return $compressed;
                        } else {
                                return $text;