From 197c54a085379b948a94c186c3ee048824152e37 Mon Sep 17 00:00:00 2001 From: ryuring Date: Sun, 13 Oct 2024 14:07:43 +0900 Subject: [PATCH] =?UTF-8?q?=E3=83=9E=E3=82=A4=E3=82=B0=E3=83=AC=E3=83=BC?= =?UTF-8?q?=E3=82=B7=E3=83=A7=E3=83=B3=E3=81=AE=E5=95=8F=E9=A1=8C=E3=82=92?= =?UTF-8?q?=E6=94=B9=E5=96=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- plugins/baser-core/src/Database/Migration/BcMigration.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/plugins/baser-core/src/Database/Migration/BcMigration.php b/plugins/baser-core/src/Database/Migration/BcMigration.php index 8cb47da5e7..14a6a57d5e 100644 --- a/plugins/baser-core/src/Database/Migration/BcMigration.php +++ b/plugins/baser-core/src/Database/Migration/BcMigration.php @@ -37,7 +37,11 @@ class BcMigration extends AbstractMigration */ public function table(string $tableName, array $options = []): Table { - $connection = $this->input->getOption('connection')?? 'default'; + if($this->input->hasParameterOption('--connection')) { + $connection = $this->input->getParameterOption('--connection'); + } else { + $connection = 'default'; + } $prefix = ConnectionManager::get($connection)->config()['prefix']; return parent::table($prefix . $tableName); }