Conditions | 3 |
Paths | 3 |
Total Lines | 16 |
Code Lines | 5 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
58 | public function request( |
||
59 | Context $ctx, |
||
60 | ServerRequest $sr, |
||
61 | int $route, |
||
62 | callable $handler = null, |
||
63 | array $params = [] |
||
64 | ) : ?Response { |
||
65 | if ($route === Dispatcher::FOUND) { |
||
66 | return null; |
||
67 | } |
||
68 | |||
69 | if ($sr->getMethod() !== 'OPTIONS') { |
||
70 | return null; |
||
71 | } |
||
72 | |||
73 | return $this->response($sr, new Response); |
||
74 | } |
||
86 |