for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Psr7Middlewares\Middleware;
use Psr7Middlewares\Utils;
use Psr7Middlewares\Middleware;
use Psr\Http\Message\RequestInterface;
use Psr\Http\Message\ResponseInterface;
/**
* Middleware to display temporary 503 maintenance pages.
*/
class Shutdown
{
use Utils\HandlerTrait;
* Execute the middleware.
*
* @param RequestInterface $request
* @param ResponseInterface $response
* @param callable $next
* @return ResponseInterface
public function __invoke(RequestInterface $request, ResponseInterface $response, callable $next)
$next
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.
$response = $this->executeHandler($request, $response);
return $response->withStatus(503);
}
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.