Index: trunk/extensions/Translate/Groups.php |
— | — | @@ -490,9 +490,7 @@ |
491 | 491 | $ids = (array) $this->conf['GROUPS']; |
492 | 492 | |
493 | 493 | foreach ( $ids as $id ) { |
494 | | - /** |
495 | | - * Do not try to include self and go to infinite loop. |
496 | | - */ |
| 494 | + // Do not try to include self and go to infinite loop. |
497 | 495 | if ( $id === $this->getId() ) { |
498 | 496 | continue; |
499 | 497 | } |
— | — | @@ -502,7 +500,7 @@ |
503 | 501 | error_log( "Invalid group id in {$this->getId()}: $id" ); |
504 | 502 | continue; |
505 | 503 | } |
506 | | - $groups[$id] = $group; |
| 504 | + $groups[$id] = $group; |
507 | 505 | } |
508 | 506 | $this->groups = $groups; |
509 | 507 | } |
— | — | @@ -513,8 +511,13 @@ |
514 | 512 | $messages = array(); |
515 | 513 | foreach ( $this->getGroups() as $group ) { |
516 | 514 | $cache = new MessageGroupCache( $group ); |
517 | | - foreach ( $cache->getKeys() as $key ) { |
518 | | - $messages[$key] = $cache->get( $key ); |
| 515 | + if ( $cache->exists() ) { |
| 516 | + foreach ( $cache->getKeys() as $key ) { |
| 517 | + $messages[$key] = $cache->get( $key ); |
| 518 | + } |
| 519 | + } else { |
| 520 | + // BC for MessageGroupOld |
| 521 | + $messages = wfArrayMerge( $messages, $group->load( 'en' ) ); |
519 | 522 | } |
520 | 523 | } |
521 | 524 | |