Permalink
Browse files

Adding common parameter handling for connection

and plugin params.
  • Loading branch information...
markstory committed May 4, 2009
1 parent 1cc3a6e commit 6180ca80c9ae24537463ed667ccfe05a58055894
Showing with 6 additions and 0 deletions.
  1. +6 −0 cake/console/libs/bake.php
@@ -52,6 +52,12 @@ function loadTasks() {
if (isset($this->{$task}) && !in_array($task, array('Project', 'DbConfig', 'Fixture'))) {
$path = Inflector::underscore(Inflector::pluralize($this->command));
$this->{$task}->path = $this->params['working'] . DS . $path . DS;
+ if (isset($this->params['connection'])) {
+ $this->{$task}->connection = $this->params['connection'];
+ }
+ if (isset($this->params['plugin'])) {
+ $this->{$task}->plugin = $this->params['plugin'];
+ }
if (!is_dir($this->{$task}->path)) {
$this->err(sprintf(__("%s directory could not be found.\nBe sure you have created %s", true), $task, $this->{$task}->path));
$this->_stop();

0 comments on commit 6180ca8

Please sign in to comment.