mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-31 09:06:17 +00:00
Fix mising connection parameter to schema objects.
When calling create/update the created schema object should be passed the current connection. Fixes #2668
This commit is contained in:
parent
f25e84f4fb
commit
46eda802e5
1 changed files with 5 additions and 1 deletions
|
@ -282,7 +282,11 @@ class SchemaShell extends AppShell {
|
|||
$this->out(__d('cake_console', 'Performing a dry run.'));
|
||||
}
|
||||
|
||||
$options = array('name' => $name, 'plugin' => $plugin);
|
||||
$options = array(
|
||||
'name' => $name,
|
||||
'plugin' => $plugin,
|
||||
'connection' => $this->params['connection'],
|
||||
);
|
||||
if (!empty($this->params['snapshot'])) {
|
||||
$fileName = rtrim($this->Schema->file, '.php');
|
||||
$options['file'] = $fileName . '_' . $this->params['snapshot'] . '.php';
|
||||
|
|
Loading…
Add table
Reference in a new issue