diff options
-rw-r--r-- | langs/report_test.php | 22 |
1 files changed, 14 insertions, 8 deletions
diff --git a/langs/report_test.php b/langs/report_test.php index a24a78f20..952e86a37 100644 --- a/langs/report_test.php +++ b/langs/report_test.php @@ -65,6 +65,14 @@ $restore_languages = FALSE; $restore_resources = FALSE; + if (isset($one_language) && $one_language != 'all') { + $otherLangs = array('en', $one_language); + $restore_languages = TRUE; + } else { + $otherLangs = get_other_langs(); + } + $times[] = time_debug('get_other_langs'); + if (isset($one_resource) && $one_resource != 'all') { $enFiles = array($one_resource); $restore_resources = TRUE; @@ -72,7 +80,7 @@ $enFiles = array_merge(array('../_nav/langs/en.pot'), get_lang_references('*.lang'), get_lang_references('*.pot')); // added navigation file /* START OF A WORKAROUND FOR TIMEOUTS */ foreach($enFiles as $enFile) { - if($enFile != 'en/about/license.pot' && $enFile != '../_nav/langs/en.pot') { + if ($restore_languages || ($enFile != 'en/about/license.pot' && $enFile != '../_nav/langs/en.pot')) { $enFiles_tmp[] = $enFile; } } @@ -81,14 +89,8 @@ sort($enFiles); } $num_of_enFiles = count($enFiles); + $times[] = time_debug('num_of_enFiles'); - if (isset($one_language) && $one_language != 'all') { - $otherLangs = array('en', $one_language); - $restore_languages = TRUE; - } else { - $otherLangs = get_other_langs(); - } - $times[] = time_debug('get_other_langs'); $enStringsCount = array(); $report = array(); @@ -369,6 +371,10 @@ } $thfiles = '<th>' . implode('</th><th>', $lang_line) . '</th>' . PHP_EOL; + if (!$restore_languages && !$restore_resources) { + echo '<p>Note that <a href="?r=../_nav/langs/en.pot" title="navigation resource">navigation resource</a> and <a href="?r=en/about/license.pot" title="license resource">license resource</a> are currently not shown in this full report as they take a significant amount of time to process.</p>'; + $count = ' '; + } if ($restore_languages) { echo '<p>Restore <a href="?l=all" title="see all languages">all languages</a>.</p>'; $count = ' '; |