Index: branches/REL1_18/phase3/includes/resourceloader/ResourceLoaderFileModule.php |
— | — | @@ -148,9 +148,13 @@ |
149 | 149 | public function __construct( $options = array(), $localBasePath = null, |
150 | 150 | $remoteBasePath = null ) |
151 | 151 | { |
152 | | - global $IP, $wgScriptPath; |
| 152 | + global $IP, $wgScriptPath, $wgResourceBasePath; |
153 | 153 | $this->localBasePath = $localBasePath === null ? $IP : $localBasePath; |
154 | | - $this->remoteBasePath = $remoteBasePath === null ? $wgScriptPath : $remoteBasePath; |
| 154 | + if ( $remoteBasePath !== null ) { |
| 155 | + $this->remoteBasePath = $remoteBasePath; |
| 156 | + } else { |
| 157 | + $this->remoteBasePath = $wgResourceBasePath === null ? $wgScriptPath : $wgResourceBasePath; |
| 158 | + } |
155 | 159 | |
156 | 160 | if ( isset( $options['remoteExtPath'] ) ) { |
157 | 161 | global $wgExtensionAssetsPath; |
— | — | @@ -258,7 +262,7 @@ |
259 | 263 | // Collect referenced files |
260 | 264 | $this->localFileRefs = array_unique( $this->localFileRefs ); |
261 | 265 | // If the list has been modified since last time we cached it, update the cache |
262 | | - if ( $this->localFileRefs !== $this->getFileDependencies( $context->getSkin() ) ) { |
| 266 | + if ( $this->localFileRefs !== $this->getFileDependencies( $context->getSkin() ) && !wfReadOnly() ) { |
263 | 267 | $dbw = wfGetDB( DB_MASTER ); |
264 | 268 | $dbw->replace( 'module_deps', |
265 | 269 | array( array( 'md_module', 'md_skin' ) ), array( |
Index: branches/REL1_18/phase3/includes/DefaultSettings.php |
— | — | @@ -1376,6 +1376,7 @@ |
1377 | 1377 | * |
1378 | 1378 | * $wgDefaultExternalStore = array( 'DB://cluster1', 'DB://cluster2' ); |
1379 | 1379 | * |
| 1380 | + * @var array |
1380 | 1381 | */ |
1381 | 1382 | $wgDefaultExternalStore = false; |
1382 | 1383 | |
— | — | @@ -2458,6 +2459,12 @@ |
2459 | 2460 | */ |
2460 | 2461 | $wgResourceModules = array(); |
2461 | 2462 | |
| 2463 | +/* |
| 2464 | + * Default 'remoteBasePath' value for resource loader modules. |
| 2465 | + * If not set, then $wgScriptPath will be used as a fallback. |
| 2466 | + */ |
| 2467 | +$wgResourceBasePath = null; |
| 2468 | + |
2462 | 2469 | /** |
2463 | 2470 | * Maximum time in seconds to cache resources served by the resource loader |
2464 | 2471 | */ |
Index: branches/REL1_18/phase3/includes/Skin.php |
— | — | @@ -281,7 +281,7 @@ |
282 | 282 | if ( User::isIP( $rootUser ) ) { |
283 | 283 | $this->mRelevantUser = User::newFromName( $rootUser, false ); |
284 | 284 | } else { |
285 | | - $user = User::newFromName( $rootUser ); |
| 285 | + $user = User::newFromName( $rootUser, false ); |
286 | 286 | if ( $user->isLoggedIn() ) { |
287 | 287 | $this->mRelevantUser = $user; |
288 | 288 | } |
Property changes on: branches/REL1_18/phase3/includes |
___________________________________________________________________ |
Modified: svn:mergeinfo |
289 | 289 | Merged /trunk/phase3/includes:r98760-98761 |
Property changes on: branches/REL1_18/phase3 |
___________________________________________________________________ |
Modified: svn:mergeinfo |
290 | 290 | Merged /trunk/phase3:r98760-98761 |