| Conditions | 3 |
| Paths | 3 |
| Total Lines | 12 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 39 | public function formatException(Exception $exception) |
||
| 40 | { |
||
| 41 | if ($exception instanceof HttpException) { |
||
| 42 | return $this->formatter->formatResponse($exception->getResponse()); |
||
| 43 | } |
||
| 44 | |||
| 45 | if ($exception instanceof TransferException) { |
||
| 46 | return $exception->getMessage(); |
||
| 47 | } |
||
| 48 | |||
| 49 | return sprintf('Unexpected exception of type "%s"', get_class($exception)); |
||
| 50 | } |
||
| 51 | |||
| 68 |