Conditions | 1 |
Paths | 1 |
Total Lines | 13 |
Lines | 0 |
Ratio | 0 % |
Tests | 7 |
CRAP Score | 1 |
Changes | 0 |
1 | <?php |
||
20 | 3 | public function getNewId( string $type = '' ): int { |
|
21 | 3 | $database = $this->loadBalancer->getConnection( DB_MASTER ); |
|
22 | |||
23 | 3 | $database->startAtomic( __METHOD__ ); |
|
24 | |||
25 | 3 | $id = $this->idDatabase->getNewId( $database, $type ); |
|
26 | |||
27 | 3 | $database->endAtomic( __METHOD__ ); |
|
28 | |||
29 | 3 | $this->loadBalancer->reuseConnection( $database ); |
|
30 | |||
31 | 3 | return $id; |
|
32 | } |
||
33 | |||
35 |