Skip to content

Commit de3d33e

Browse files
committed
refactor: clean up parentheses on assign and ternary
1 parent 5aaecd6 commit de3d33e

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

system/Database/BaseConnection.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -848,7 +848,7 @@ public function transBegin(bool $testMode = false): bool
848848
// Reset the transaction failure flag.
849849
// If the $test_mode flag is set to TRUE transactions will be rolled back
850850
// even if the queries produce a successful result.
851-
$this->transFailure = ($testMode);
851+
$this->transFailure = $testMode;
852852

853853
if ($this->_transBegin()) {
854854
$this->transDepth++;

system/Database/MySQLi/Connection.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ public function connect(bool $persistent = false)
9696
$port = null;
9797
$socket = $this->hostname;
9898
} else {
99-
$hostname = ($persistent) ? 'p:' . $this->hostname : $this->hostname;
99+
$hostname = $persistent ? 'p:' . $this->hostname : $this->hostname;
100100
$port = empty($this->port) ? null : $this->port;
101101
$socket = '';
102102
}

0 commit comments

Comments
 (0)