Skip to content

Commit c685781

Browse files
committed
refactor: replace empty()
1 parent 9186487 commit c685781

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

phpstan-baseline.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3106,7 +3106,7 @@
31063106
$ignoreErrors[] = [
31073107
// identifier: empty.notAllowed
31083108
'message' => '#^Construct empty\\(\\) is not allowed\\. Use more strict comparison\\.$#',
3109-
'count' => 3,
3109+
'count' => 2,
31103110
'path' => __DIR__ . '/system/Database/OCI8/Connection.php',
31113111
];
31123112
$ignoreErrors[] = [

system/Database/OCI8/Connection.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -632,7 +632,7 @@ protected function buildDSN()
632632
}
633633

634634
$isEasyConnectableHostName = $this->hostname !== '' && ! str_contains($this->hostname, '/') && ! str_contains($this->hostname, ':');
635-
$easyConnectablePort = ! empty($this->port) && ctype_digit((string) $this->port) ? ':' . $this->port : '';
635+
$easyConnectablePort = ($this->port !== '') && ctype_digit((string) $this->port) ? ':' . $this->port : '';
636636
$easyConnectableDatabase = $this->database !== '' ? '/' . ltrim($this->database, '/') : '';
637637

638638
if ($isEasyConnectableHostName && ($easyConnectablePort !== '' || $easyConnectableDatabase !== '')) {

0 commit comments

Comments
 (0)