mirror of
https://github.com/archtechx/tenancy.git
synced 2026-05-07 00:04:04 +00:00
Use parameter binding in SELECT queries
This commit is contained in:
parent
808f52765c
commit
ad7d229daf
8 changed files with 10 additions and 10 deletions
|
|
@ -20,7 +20,7 @@ class PostgreSQLSchemaManager extends TenantDatabaseManager
|
|||
|
||||
public function databaseExists(string $name): bool
|
||||
{
|
||||
return (bool) $this->connection()->select("SELECT schema_name FROM information_schema.schemata WHERE schema_name = '$name'");
|
||||
return (bool) $this->connection()->select("SELECT schema_name FROM information_schema.schemata WHERE schema_name = ?", [$name]);
|
||||
}
|
||||
|
||||
public function makeConnectionConfig(array $baseConfig, string $databaseName): array
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue