Commit 90460aab authored by Luke Duncalfe's avatar Luke Duncalfe

Merge branch '339431-fj-remove-group-including-descendants-ff' into 'master'

Enable linear version of `groups_including_descendants_by`

See merge request gitlab-org/gitlab!74275
parents bcdec579 0bb75d09
......@@ -852,15 +852,7 @@ class Group < Namespace
end
def self.groups_including_descendants_by(group_ids)
groups = Group.where(id: group_ids)
if Feature.enabled?(:linear_group_including_descendants_by, default_enabled: :yaml)
groups.self_and_descendants
else
Gitlab::ObjectHierarchy
.new(groups)
.base_and_descendants
end
Group.where(id: group_ids).self_and_descendants
end
def disable_shared_runners!
......
---
name: linear_group_including_descendants_by
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/68835
rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/339431
milestone: '14.3'
type: development
group: group::access
default_enabled: false
......@@ -2325,14 +2325,6 @@ RSpec.describe Group do
end
it_behaves_like 'returns the expected groups for a group and its descendants'
context 'when :linear_group_including_descendants_by feature flag is disabled' do
before do
stub_feature_flags(linear_group_including_descendants_by: false)
end
it_behaves_like 'returns the expected groups for a group and its descendants'
end
end
describe '.preset_root_ancestor_for' do
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment