Commit 80cc465d authored by Ethan Urie's avatar Ethan Urie

Remove check for gitlab employee badge feature

The `#gitlab_employee?` method would return false if the
Feature flag `gitlab_employee_badge` was enabled. Since this feature
flag only added a special badge to gitlab employees and didn't affect
the actual check, we're removing it. It was actually harming spam checks
which will allow issue creation without checking for spam if the user is
a gitlab employee. Since this feature flag is disabled, it always
failed.
parent 9177d6ef
......@@ -343,7 +343,7 @@ module EE
def gitlab_employee?
strong_memoize(:gitlab_employee) do
::Gitlab.com? && ::Feature.enabled?(:gitlab_employee_badge) && gitlab_team_member?
::Gitlab.com? && gitlab_team_member?
end
end
......
......@@ -1467,18 +1467,6 @@ RSpec.describe User do
it { is_expected.to be false }
end
end
context 'when `:gitlab_employee_badge` feature flag is disabled' do
let(:user) { create(:user) }
before do
allow(Gitlab).to receive(:com?).and_return(true)
stub_feature_flags(gitlab_employee_badge: false)
gitlab_group.add_user(user, Gitlab::Access::DEVELOPER)
end
it { is_expected.to be false }
end
end
describe '#gitlab_bot?' 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