1 | <?php |
||
2 | |||
3 | use Psr\Http\Message\ServerRequestInterface; |
||
4 | use Psr\Http\Message\ResponseInterface; |
||
5 | use \HotRodCli\Api\Processor; |
||
6 | use \HotRodCli\Api\GetCommands; |
||
7 | |||
8 | /** @var \Slim\App $api */ |
||
9 | $api->post('/create/{command}', function (ServerRequestInterface $request, ResponseInterface $response, $args) use ($app) { |
||
10 | return $response->getBody()->write($app->resolve(Processor::class)($request, $args)); |
||
11 | }); |
||
12 | |||
13 | $api->get('/commands', function(ServerRequestInterface $request, ResponseInterface $response, $arg) use ($app) { |
||
0 ignored issues
–
show
|
|||
14 | return $response->getBody()->write($app->resolve(GetCommands::class)()); |
||
15 | }); |
This check looks for parameters that have been defined for a function or method, but which are not used in the method body.