Skip to content

Commit

Permalink
#992554 by greg.1.anderson: Improve drush function names for function…
Browse files Browse the repository at this point in the history
…s where drush calls back in to drush
  • Loading branch information
greg-1-anderson committed Dec 9, 2010
1 parent c75a203 commit 0b71c7f
Show file tree
Hide file tree
Showing 7 changed files with 299 additions and 206 deletions.
4 changes: 2 additions & 2 deletions commands/core/image.drush.inc
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ function drush_image_flush($style_name = NULL) {
}
else {
$commands = drush_get_commands();
return drush_redispatch($commands['image-flush'], array($style_name));
return drush_dispatch($commands['image-flush'], array($style_name));
}
}
else {
Expand All @@ -63,4 +63,4 @@ function drush_image_flush_all() {
image_style_flush($style);
}
drush_log(dt('All image styles flushed'), 'success');
}
}
2 changes: 1 addition & 1 deletion commands/core/topic.drush.inc
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ function drush_topic_core_topic($topic_name = NULL) {
if (!isset($commands[$topic_name]) && isset($commands["docs-$topic_name"])) {
$topic_name = "docs-$topic_name";
}
return drush_redispatch($commands[$topic_name]);
return drush_dispatch($commands[$topic_name]);
}

/**
Expand Down
2 changes: 1 addition & 1 deletion commands/sql/sync.sql.inc
Original file line number Diff line number Diff line change
Expand Up @@ -481,7 +481,7 @@ function drush_sql_post_sql_sync($source = NULL, $destination = NULL) {
}
if ($sanitize_query) {
if (!drush_get_context('DRUSH_SIMULATE')) {
$result = drush_do_site_command($destination_settings, "sql-query", array($sanitize_query));
$result = drush_invoke_sitealais_args($destination_settings, "sql-query", array($sanitize_query));
}
else {
drush_print("Executing on $destination: $sanitize_query");
Expand Down
5 changes: 5 additions & 0 deletions drush.php
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,11 @@ function drush_main() {
// Dispatch the command(s).
$return = drush_dispatch($command);

// prevent a '1' at the end of the output
if ($return === TRUE) {
$return = '';
}

if (drush_get_context('DRUSH_DEBUG')) {
drush_print_timers();
}
Expand Down
Loading

0 comments on commit 0b71c7f

Please sign in to comment.