protected function routeMiddleware($key, $middleware = null, $force = false)
    {
        if ($this->app->runningInConsole() && $force === false) {
            return $this->getRouter();
        }
        if (is_array($key)) {
            foreach ($key as $k => $m) {
                $this->routeMiddleware($k, $m);
            }

            return $this->getRouter();
        } else {
            $this->getRouter()->middleware($key, $middleware);
        }
    }