@@ -95,7 +95,7 @@ discard block |
||
| 95 | 95 | |
| 96 | 96 | $this->expectException(Exception::class); |
| 97 | 97 | |
| 98 | - $db->transaction(function () use ($db) { |
|
| 98 | + $db->transaction(function() use ($db) { |
|
| 99 | 99 | $db->createCommand()->insert('profile', ['description' => 'test transaction shortcut'])->execute(); |
| 100 | 100 | throw new Exception('Exception in transaction shortcut'); |
| 101 | 101 | }); |
@@ -109,7 +109,7 @@ discard block |
||
| 109 | 109 | { |
| 110 | 110 | $db = $this->getConnection(true); |
| 111 | 111 | |
| 112 | - $result = $db->transaction(static function () use ($db) { |
|
| 112 | + $result = $db->transaction(static function() use ($db) { |
|
| 113 | 113 | $db->createCommand()->insert('profile', ['description' => 'test transaction shortcut'])->execute(); |
| 114 | 114 | return true; |
| 115 | 115 | }); |
@@ -127,7 +127,7 @@ discard block |
||
| 127 | 127 | { |
| 128 | 128 | $db = $this->getConnection(true); |
| 129 | 129 | |
| 130 | - $result = $db->transaction(static function (ConnectionInterface $db) { |
|
| 130 | + $result = $db->transaction(static function(ConnectionInterface $db) { |
|
| 131 | 131 | $db->createCommand()->insert('profile', ['description' => 'test transaction shortcut'])->execute(); |
| 132 | 132 | return true; |
| 133 | 133 | }, Transaction::READ_UNCOMMITTED); |
@@ -150,10 +150,10 @@ discard block |
||
| 150 | 150 | { |
| 151 | 151 | $db = $this->getConnection(); |
| 152 | 152 | |
| 153 | - $db->transaction(function (ConnectionInterface $db) { |
|
| 153 | + $db->transaction(function(ConnectionInterface $db) { |
|
| 154 | 154 | $this->assertNotNull($db->getTransaction()); |
| 155 | 155 | |
| 156 | - $db->transaction(function (ConnectionInterface $db) { |
|
| 156 | + $db->transaction(function(ConnectionInterface $db) { |
|
| 157 | 157 | $this->assertNotNull($db->getTransaction()); |
| 158 | 158 | $db->getTransaction()->rollBack(); |
| 159 | 159 | }); |
@@ -168,7 +168,7 @@ discard block |
||
| 168 | 168 | |
| 169 | 169 | $db->setEnableSavepoint(false); |
| 170 | 170 | |
| 171 | - $db->transaction(function (ConnectionInterface $db) { |
|
| 171 | + $db->transaction(function(ConnectionInterface $db) { |
|
| 172 | 172 | $this->assertNotNull($db->getTransaction()); |
| 173 | 173 | $this->expectException(NotSupportedException::class); |
| 174 | 174 | $db->beginTransaction(); |
@@ -581,7 +581,7 @@ discard block |
||
| 581 | 581 | { |
| 582 | 582 | $table = $this->db->quoteSql($table); |
| 583 | 583 | |
| 584 | - $columns = array_map(fn ($column) => $this->db->quoteSql($column), $columns); |
|
| 584 | + $columns = array_map(fn($column) => $this->db->quoteSql($column), $columns); |
|
| 585 | 585 | |
| 586 | 586 | $params = []; |
| 587 | 587 | |
@@ -1288,7 +1288,7 @@ discard block |
||
| 1288 | 1288 | $cacheKey = $this->getCacheKey($method, $fetchMode, $rawSql); |
| 1289 | 1289 | $result = $cache->getOrSet( |
| 1290 | 1290 | $cacheKey, |
| 1291 | - static fn () => null, |
|
| 1291 | + static fn() => null, |
|
| 1292 | 1292 | ); |
| 1293 | 1293 | |
| 1294 | 1294 | if (is_array($result) && isset($result[0])) { |
@@ -1340,7 +1340,7 @@ discard block |
||
| 1340 | 1340 | if (isset($cache, $cacheKey, $info)) { |
| 1341 | 1341 | $cache->getOrSet( |
| 1342 | 1342 | $cacheKey, |
| 1343 | - static fn (): array => [$result], |
|
| 1343 | + static fn(): array => [$result], |
|
| 1344 | 1344 | $info[1], |
| 1345 | 1345 | $info[2] |
| 1346 | 1346 | ); |
@@ -1464,7 +1464,7 @@ discard block |
||
| 1464 | 1464 | && $this->isolationLevel !== null |
| 1465 | 1465 | && $this->db->getTransaction() === null |
| 1466 | 1466 | ) { |
| 1467 | - $this->db->transaction(fn ($rawSql) => $this->internalExecute($rawSql), $this->isolationLevel); |
|
| 1467 | + $this->db->transaction(fn($rawSql) => $this->internalExecute($rawSql), $this->isolationLevel); |
|
| 1468 | 1468 | } else { |
| 1469 | 1469 | $this->pdoStatement->execute(); |
| 1470 | 1470 | } |
@@ -73,7 +73,7 @@ |
||
| 73 | 73 | { |
| 74 | 74 | return preg_replace_callback( |
| 75 | 75 | '/({{(%?[\w\-. ]+%?)}}|\\[\\[([\w\-. ]+)]])/', |
| 76 | - function ($matches) { |
|
| 76 | + function($matches) { |
|
| 77 | 77 | if (isset($matches[3])) { |
| 78 | 78 | return $this->quoteColumnName($matches[3]); |
| 79 | 79 | } |