| Conditions | 1 |
| Paths | 1 |
| Total Lines | 8 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 6 |
| CRAP Score | 1 |
| Changes | 0 | ||
| 1 | <?php declare(strict_types=1); |
||
| 7 | 1 | public static function methodNotAllowed($uri, $method, $allowedMethods) |
|
| 8 | { |
||
| 9 | 1 | $allowedMethods = implode(', ', $allowedMethods); |
|
| 10 | 1 | $exception = new self( |
|
| 11 | 1 | "Method `$method` not allowed. This uri `$uri` allows only $allowedMethods http methods.", |
|
| 12 | 1 | 405 |
|
| 13 | ); |
||
| 14 | 1 | return $exception; |
|
| 15 | } |
||
| 17 |