Skip to content

Commit d984a05

Browse files
committed
schema name in pdoconnector
1 parent 5eb0311 commit d984a05

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

src/Storage/PDOConnector.php

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@ class PDOConnector implements IStorageConnector {
4141
private $statement = null;
4242
/** @var bool $transactionExists */
4343
private $transactionExists = false;
44+
/** @var string|null $schemaName */
45+
private $schemaName = null;
4446

4547
/**
4648
* sets the credentials used to connect against the database
@@ -49,6 +51,14 @@ class PDOConnector implements IStorageConnector {
4951
*/
5052
public function setCredentials(array $credentials) {
5153
$this->credentials = $credentials;
54+
$this->schemaName = $credentials["dbname"];
55+
}
56+
57+
/**
58+
* @return string|null
59+
*/
60+
public function getSchema(): ?string {
61+
return $this->schemaName;
5262
}
5363

5464
/**

0 commit comments

Comments
 (0)