Révision 503b3f7b
Ajouté par Assos Assos il y a environ 10 ans
drupal7/sites/all/modules/l10n_update/l10n_update.batch.inc | ||
---|---|---|
172 | 172 |
$file = $context['results'][$id]['file']; |
173 | 173 |
} |
174 | 174 |
if ($file) { |
175 |
// Create a result if none exists yet. |
|
176 |
if (!isset($context['results'][$id])) { |
|
177 |
$context['results'][$id] = array(); |
|
178 |
} |
|
175 | 179 |
if ($import_result = l10n_update_source_import($file, $mode)) { |
176 | 180 |
$context['message'] = $t('Imported: %name.', array('%name' => $file->filename)); |
177 | 181 |
$context['results'][$id] = array_merge((array)$context['results'][$id], $import_result, array('file' => $file)); |
... | ... | |
249 | 253 |
array('!log_messages' => l(t('Recent log messages'), 'admin/reports/dblog'))), |
250 | 254 |
'warning'); |
251 | 255 |
} |
256 |
|
|
257 |
// Clear cache and force refresh of JavaScript translations and rebuild |
|
258 |
// the menu as strings may have changed. |
|
259 |
foreach (array_keys($totals) as $langcode) { |
|
260 |
_locale_invalidate_js($langcode); |
|
261 |
} |
|
262 |
cache_clear_all('locale:', 'cache', TRUE); |
|
263 |
menu_rebuild(); |
|
252 | 264 |
} |
253 | 265 |
|
254 | 266 |
// Error for failed imports. |
Formats disponibles : Unified diff
Weekly update of contrib modules