for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
use Psr\Http\Message\ServerRequestInterface;
use Psr\Http\Message\ResponseInterface;
use \HotRodCli\Api\Processor;
use \HotRodCli\Api\GetCommands;
/** @var \Slim\App $api */
$api->post('/create/{command}', function (ServerRequestInterface $request, ResponseInterface $response, $args) use ($app) {
return $response->getBody()->write($app->resolve(Processor::class)($request, $args));
});
$api->get('/commands', function(ServerRequestInterface $request, ResponseInterface $response, $arg) use ($app) {
$arg
If this is a false-positive, you can also ignore this issue in your code via the ignore-unused annotation
ignore-unused
$api->get('/commands', function(ServerRequestInterface $request, ResponseInterface $response, /** @scrutinizer ignore-unused */ $arg) use ($app) {
This check looks for parameters that have been defined for a function or method, but which are not used in the method body.
return $response->getBody()->write($app->resolve(GetCommands::class)());
This check looks for parameters that have been defined for a function or method, but which are not used in the method body.