Skip to content

Commit

Permalink
Merge pull request #635 from pabloelcolombiano/3.x
Browse files Browse the repository at this point in the history
#633 Quote schema for PostgreSQL in the CakeAdapter
  • Loading branch information
dereuromark authored Sep 14, 2023
2 parents f4397bd + 21061d6 commit 633cc85
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/CakeAdapter.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public function __construct(AdapterInterface $adapter, ?Connection $connection =
if ($connection->getDriver() instanceof Postgres) {
$config = $connection->config();
$schema = empty($config['schema']) ? 'public' : $config['schema'];
$pdo->exec('SET search_path TO ' . $schema);
$pdo->exec('SET search_path TO ' . $pdo->quote($schema));
}
$connection->getDriver()->setConnection($pdo);
}
Expand Down

0 comments on commit 633cc85

Please sign in to comment.