We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5ee0df2 commit 99346b4Copy full SHA for 99346b4
system/Database/OCI8/Connection.php
@@ -104,6 +104,10 @@ class Connection extends BaseConnection
104
*/
105
private function isValidDSN(): bool
106
{
107
+ if ($this->DSN === null || $this->DSN === '') {
108
+ return false;
109
+ }
110
+
111
foreach ($this->validDSNs as $regexp) {
112
if (preg_match($regexp, $this->DSN)) {
113
return true;
@@ -120,7 +124,7 @@ private function isValidDSN(): bool
120
124
121
125
public function connect(bool $persistent = false)
122
126
123
- if ($this->DSN === null || $this->DSN === '' || ! $this->isValidDSN()) {
127
+ if (! $this->isValidDSN()) {
128
$this->buildDSN();
129
}
130
0 commit comments