File tree Expand file tree Collapse file tree 2 files changed +6
-1
lines changed
Expand file tree Collapse file tree 2 files changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -174,6 +174,11 @@ function onSubmit() {
174174 // Clients may not set the client_group_id, so we unset them if user is not a admin
175175 if (!$ app ->auth ->has_clients ($ _SESSION ['s ' ]['user ' ]['userid ' ])) unset($ this ->dataRecord ["client_group_id " ]);
176176 }
177+
178+ //* make sure that the email domain is lowercase
179+ if (isset ($ this ->dataRecord ["domain " ])) $ this ->dataRecord ["domain " ] = strtolower ($ this ->dataRecord ["domain " ]);
180+
181+
177182 parent ::onSubmit ();
178183 }
179184
Original file line number Diff line number Diff line change @@ -160,7 +160,7 @@ function onSubmit() {
160160
161161 //* compose the email field
162162 if (isset ($ _POST ["email_local_part " ]) && isset ($ _POST ["email_domain " ])) {
163- $ this ->dataRecord ["email " ] = $ _POST ["email_local_part " ]."@ " .$ _POST ["email_domain " ];
163+ $ this ->dataRecord ["email " ] = strtolower ( $ _POST ["email_local_part " ]."@ " .$ _POST ["email_domain " ]) ;
164164
165165 // Set the server id of the mailbox = server ID of mail domain.
166166 $ this ->dataRecord ["server_id " ] = $ domain ["server_id " ];
You can’t perform that action at this time.
0 commit comments