protected function middleware($middlewareClass, ...$params)
    {
        $middleware = new $middlewareClass(static::class, ...$params);

        $this->{Services::APP}->attach($middleware);

        return $middleware;
    }