diff --git a/src/Util/TableFinder.php b/src/Util/TableFinder.php index c9cbe392..405cb897 100644 --- a/src/Util/TableFinder.php +++ b/src/Util/TableFinder.php @@ -82,7 +82,7 @@ public function getTablesToBake(CollectionInterface $collection, array $options $config = (array)ConnectionManager::getConfig($this->connection); $key = isset($config['schema']) ? 'schema' : 'database'; - if (isset($split[0]) && $config[$key] === $split[1]) { + if (isset($split[0], $split[1]) && $config[$key] === $split[1]) { $table = $split[0]; } } @@ -197,7 +197,7 @@ public function fetchTableName(string $className, ?string $pluginName = null): a $config = ConnectionManager::getConfig($this->connection); if ($config) { $key = isset($config['schema']) ? 'schema' : 'database'; - if (isset($splitted[0]) && $config[$key] === $splitted[1]) { + if (isset($splitted[0], $splitted[1]) && $config[$key] === $splitted[1]) { $tableName = $splitted[0]; } }