Commit 9248354a authored by Martin Wortschack's avatar Martin Wortschack

Merge branch 'nicolasdular/rm-email-restriction-ff' into 'master'

Remove email restrictions feature flag

See merge request gitlab-org/gitlab!30548
parents 17865b69 1cbb0a60
......@@ -1786,7 +1786,6 @@ class User < ApplicationRecord
end
def check_email_restrictions
return unless Feature.enabled?(:email_restrictions)
return unless Gitlab::CurrentSettings.email_restrictions_enabled?
restrictions = Gitlab::CurrentSettings.email_restrictions
......
......@@ -49,7 +49,6 @@
= f.label :domain_blacklist, 'Blacklisted domains for sign-ups', class: 'label-bold'
= f.text_area :domain_blacklist_raw, placeholder: 'domain.com', class: 'form-control', rows: 8
.form-text.text-muted Users with e-mail addresses that match these domain(s) will NOT be able to sign-up. Wildcards allowed. Use separate lines for multiple entries. Ex: domain.com, *.domain.com
- if Feature.enabled?(:email_restrictions)
.form-group
= f.label :email_restrictions_enabled, _('Email restrictions'), class: 'label-bold'
.form-check
......
---
title: Add option to restrict emails that match a configured regular expression
merge_request: 30548
author:
type: added
......@@ -538,18 +538,6 @@ describe User, :do_not_mock_admin_mode do
expect(user).to be_valid
end
context 'when feature flag is turned off' do
before do
stub_feature_flags(email_restrictions: false)
end
it 'does accept the email address' do
user = build(:user, email: 'info+1@test.com')
expect(user).to be_valid
end
end
context 'when created_by_id is set' do
it 'does accept the email address' do
user = build(:user, email: 'info+1@test.com', created_by_id: 1)
......
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