Index: trunk/phase3/includes/MessageCache.php |
— | — | @@ -264,7 +264,7 @@ |
265 | 265 | $success = $this->setCache( $cache ); |
266 | 266 | if ( $success ) { |
267 | 267 | $where[] = 'got from global cache'; |
268 | | - $this->saveToCaches( $cache, $cacheKey, false ); |
| 268 | + $this->saveToCaches( $cache, $cacheKey, false, $code ); |
269 | 269 | } |
270 | 270 | wfProfileOut( __METHOD__ . '-fromcache' ); |
271 | 271 | } |
— | — | @@ -283,7 +283,7 @@ |
284 | 284 | $success = $this->setCache( $cache ); |
285 | 285 | wfProfileOut( __METHOD__ . '-load' ); |
286 | 286 | if ( $success ) { |
287 | | - $this->saveToCaches( $cache, $cacheKey ); |
| 287 | + $this->saveToCaches( $cache, $cacheKey, true, $code ); |
288 | 288 | } |
289 | 289 | $this->unlock($cacheKey); |
290 | 290 | } |
— | — | @@ -413,7 +413,7 @@ |
414 | 414 | $success = $this->setCache( $cache, $cacheKey ); |
415 | 415 | if ( $success ) { |
416 | 416 | # And then all caches |
417 | | - $this->saveToCaches( $cache, $cacheKey ); |
| 417 | + $this->saveToCaches( $cache, $cacheKey, true, $code ); |
418 | 418 | } |
419 | 419 | } |
420 | 420 | $this->unlock($cacheKey); |
— | — | @@ -430,9 +430,10 @@ |
431 | 431 | * @param $cache Array: cached messages with a version. |
432 | 432 | * @param $cacheKey String: Identifier for the cache. |
433 | 433 | * @param $memc Bool: Wether to update or not memcache. |
| 434 | + * @param $code String: Language code. |
434 | 435 | * @return False on somekind of error. |
435 | 436 | */ |
436 | | - protected function saveToCaches( $cache, $cacheKey, $memc = true ) { |
| 437 | + protected function saveToCaches( $cache, $cacheKey, $memc = true, $code = false ) { |
437 | 438 | wfProfileIn( __METHOD__ ); |
438 | 439 | global $wgLocalMessageCache, $wgLocalMessageCacheSerialized; |
439 | 440 | |