File tree Expand file tree Collapse file tree 3 files changed +4
-3
lines changed Expand file tree Collapse file tree 3 files changed +4
-3
lines changed Original file line number Diff line number Diff line change 7979 min_threads : 2
8080 max_threads : 24
8181 api_user :
82+ email_regex : " \\ A[^@\\ s]+@[^@\\ s]+\\ .[^@\\ s]+\\ z"
8283 first_name_exclude_regex : " (http|https|www|<|>|\\ r|\\ n)"
8384 last_name_exclude_regex : " (http|https|www|<|>|\\ r|\\ n)"
8485 admin :
8586 initial_superusers : []
8687 username_is_email : true
8788 password_length_min : 14
8889 password_length_max : 72
89- email_regex : " \\ A[^@\\ s]+@[^@\\ s]+\\ z"
90+ email_regex : " \\ A[^@\\ s]+@[^@\\ s]+\\ .[^@ \\ s]+ \\ z"
9091 password_regex :
9192 auth_strategies :
9293 enabled :
Original file line number Diff line number Diff line change @@ -59,7 +59,7 @@ class ApiUser
5959 validates :email ,
6060 :presence => { :message => "Provide your email address." } ,
6161 :format => {
62- :with => /.+@.+ \. .+/ ,
62+ :with => proc { :: Regexp . new ( ApiUmbrellaConfig [ :web ] [ :api_user ] [ :email_regex ] , :: Regexp :: IGNORECASE ) } ,
6363 :allow_blank => true ,
6464 :message => "Provide a valid email address." ,
6565 } ,
Original file line number Diff line number Diff line change 161161 # Email regex used to validate email formats. It simply asserts that
162162 # one (and only one) @ exists in the given string. This is mainly
163163 # to give user feedback and not to assert the e-mail validity.
164- config . email_regexp = Regexp . new ( ApiUmbrellaConfig [ :web ] [ :admin ] [ :email_regex ] )
164+ config . email_regexp = :: Regexp . new ( ApiUmbrellaConfig [ :web ] [ :admin ] [ :email_regex ] , :: Regexp :: IGNORECASE )
165165
166166 # ==> Configuration for :timeoutable
167167 # The time you want to timeout the user session without activity. After this
You can’t perform that action at this time.
0 commit comments