Bolt\Controller\ConfigurableBase::resolveAfter PHP Method

resolveAfter() protected method

Returns a closure that will resolve the middleware callback to call on kernel response and call it.
protected resolveAfter ( array | string | null $after ) : Closure
$after array | string | null
return Closure
    protected function resolveAfter($after)
    {
        $getAfter = $this->resolveMiddleware($after);
        return function (Request $request, Response $response, Application $app) use($getAfter) {
            $callback = $getAfter($request);
            if (!is_callable($callback)) {
                return null;
            }
            return call_user_func($callback, $request, $response, $app);
        };
    }