function l10n_update_batch_import in Localization update 6
Same name and namespace in other branches
- 7.2 l10n_update.bulk.inc \l10n_update_batch_import()
- 7 l10n_update.batch.inc \l10n_update_batch_import()
Create a batch to just import files.
All update sources must have a 'filepath'.
Parameters
$updates: Translations sources to be imported. Note: All update sources must have a 'fileurl'.
$import_mode: Import mode. How to treat existing and modified translations.
Return value
array A batch definition for this import.
File
- ./
l10n_update.batch.inc, line 40
Code
function l10n_update_batch_import($updates, $import_mode) {
foreach ($updates as $update) {
$id = $update->filename;
$operations[] = array(
'_l10n_update_batch_import',
array(
$id,
$update,
$import_mode,
),
);
}
return _l10n_update_create_batch($operations);
}