recovering previous behaviour when enotif is switched off
[lhc/web/wiklou.git] / maintenance / redundanttrans.php
1 <?php
2 /**
3 * Prints out messages that are no longer used.
4 *
5 * @package MediaWiki
6 * @subpackage Maintenance
7 */
8
9 require_once('commandLine.inc');
10
11 if ( 'en' == $wgLanguageCode ) {
12 print "Current selected language is English. Cannot check translations.\n";
13 exit();
14 }
15
16 $count = $total = 0;
17 $msgarray = 'wgAllMessages' . ucfirst( $wgLanguageCode );
18
19 foreach ( $$msgarray as $code => $msg ) {
20 ++$total;
21 if ( ! array_key_exists( $code, $wgAllMessagesEn ) ) {
22 print "* $code\n";
23 ++$count;
24 }
25 }
26
27 print "{$count} messages of {$total} are redundant\n";
28 ?>