Only show usage quota view for root ancestor namespaces
What does this MR do and why?
There was an unintended case where you could see the pages usage quota view in a group that was not the root level namespace (group/group
).
This change hides the usage quota tab for non-root namespaces. This change allows simplifying the count_versioned_deployments_for
method in pages_deployment.rb
as well.
How to set up and validate locally
- Ensure you have a group with an ultimate license.
- create a subgroup.
- inside that subgroups sidebar, go to settings > usage quotas.
- Ensure the "Pages" tab is no longer visible.
Edited by Janis Altherr