private function applyGroupAttributes(RouteBuilder $routeBuilder): void
    {
        $groupAttributes = [];

        foreach ($this->groupOptionsStack as $groupOptions) {
            $groupAttributes = \array_merge($groupAttributes, $groupOptions->attributes);
        }

        $routeBuilder->withManyAttributes($groupAttributes);
    }