Conditions | 2 |
Paths | 2 |
Total Lines | 8 |
Code Lines | 4 |
Lines | 0 |
Ratio | 0 % |
Tests | 5 |
CRAP Score | 2 |
Changes | 0 |
1 | <?php |
||
21 | 2 | public function index(Request $request) : Response |
|
22 | { |
||
23 | 2 | if (Request::METHOD_POST !== $request->getMethod()) { |
|
24 | 1 | return new Response('A JSON-RPC HTTP call must use POST', Response::HTTP_METHOD_NOT_ALLOWED); |
|
25 | } |
||
26 | |||
27 | 1 | return new Response( |
|
28 | 1 | $this->sdkEndpoint->index($request->getContent()) |
|
29 | ); |
||
32 |