Conditions | 1 |
Paths | 1 |
Total Lines | 19 |
Code Lines | 13 |
Lines | 0 |
Ratio | 0 % |
Tests | 10 |
CRAP Score | 1.0007 |
Changes | 0 |
1 | <?php |
||
36 | 2 | public function format( |
|
37 | TransactionRolledBackExceptionInterface $rollback |
||
38 | ): string { |
||
39 | 2 | return implode( |
|
40 | 2 | PHP_EOL, |
|
41 | array_reduce( |
||
42 | 2 | $rollback->getFailures(), |
|
43 | function ( |
||
44 | array $carry, |
||
45 | OperationFailureInterface $failure |
||
46 | ): array { |
||
47 | 1 | $carry[] = $this->failureFormatter->format($failure); |
|
48 | |||
49 | 1 | return $carry; |
|
50 | 2 | }, |
|
51 | [ |
||
52 | 2 | $rollback->getMessage(), |
|
53 | 2 | '', |
|
54 | 2 | 'Stacktrace:' |
|
55 | ] |
||
60 |