diff --git a/l10n_update.drush.inc b/l10n_update.drush.inc index 07c55d3..ccbec7b 100644 --- a/l10n_update.drush.inc +++ b/l10n_update.drush.inc @@ -21,7 +21,6 @@ function l10n_update_drush_help($section) { */ function l10n_update_drush_command() { $commands['l10n-update'] = array( - 'callback' => 'l10n_update_drush_update', 'description' => 'Updates translations.', 'arguments' => array( 'check' => 'Number of translation files to check.', @@ -41,9 +40,10 @@ function l10n_update_drush_command() { * @param $before * Number of days, check only updates that haven't been checked for this time */ -function l10n_update_drush_update($count = 10, $limit = 10, $before = NULL) { +function drush_l10n_update($count = 10, $limit = 10, $before = NULL) { $before = isset($before) ? $before : variable_get('l10n_update_check_frequency', 0); module_load_include('check.inc', 'l10n_update'); list($checked, $updated) = l10n_update_check_translations($count, REQUEST_TIME - $before * 24 * 3600, $limit); - return dt('Checked @checked translations, updated @updated.', array('@checked' => count($checked), '@updated' => count($updated))); + $msg = dt('Checked @checked translations, updated @updated.', array('@checked' => count($checked), '@updated' => count($updated))); + drush_print("\n" . $msg . "\n"); }