* @file
*/
-if ( !defined( 'MEDIAWIKI' ) ) {
- die( 1 );
-}
-
/**
* This class should be covered by a general architecture document which does
* not exist as of January 2011. This is one of the Core classes and should
return $cookies;
}
- /**
- * Return whether this page is not cacheable because "useskin" or "uselang"
- * URL parameters were passed.
- *
- * @return Boolean
- */
- function uncacheableBecauseRequestVars() {
- $request = $this->getRequest();
- return $request->getText( 'useskin', false ) === false
- && $request->getText( 'uselang', false ) === false;
- }
-
/**
* Check if the request has a cache-varying cookie header
* If it does, it's very important that we don't allow public caching
$headers = array();
foreach( $this->mVaryHeader as $header => $option ) {
$newheader = $header;
- if( is_array( $option ) ) {
+ if ( is_array( $option ) && count( $option ) > 0 ) {
$newheader .= ';' . implode( ';', $option );
}
$headers[] = $newheader;
$response->header( $this->getXVO() );
}
- if( !$this->uncacheableBecauseRequestVars() && $this->mEnableClientCache ) {
+ if( $this->mEnableClientCache ) {
if(
$wgUseSquid && session_id() == '' && !$this->isPrintable() &&
$this->mSquidMaxage != 0 && !$this->haveCacheVaryCookies()