Proyectos de Subversion Moodle

Rev

Rev 1 | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 1 Rev 1441
Línea 35... Línea 35...
35
    public function __construct(callable $nextHandler)
35
    public function __construct(callable $nextHandler)
36
    {
36
    {
37
        $this->nextHandler = $nextHandler;
37
        $this->nextHandler = $nextHandler;
38
    }
38
    }
Línea 39... Línea 39...
39
 
39
 
40
    public function __invoke(CommandInterface $command, RequestInterface $request = null)
40
    public function __invoke(CommandInterface $command, ?RequestInterface $request = null)
41
    {
41
    {
42
        $next = $this->nextHandler;
42
        $next = $this->nextHandler;
43
        return $next($command, $request)->then(
43
        return $next($command, $request)->then(
44
            function (ResultInterface $result) use ($command) {
44
            function (ResultInterface $result) use ($command) {