mirror of
https://github.com/simple-login/app.git
synced 2024-11-17 22:21:38 +08:00
format
This commit is contained in:
parent
9bb17533c1
commit
dfb427e6da
1 changed files with 2 additions and 3 deletions
|
@ -48,9 +48,8 @@ def mailbox_detail_route(mailbox_id):
|
||||||
new_email = change_email_form.email.data.lower().strip()
|
new_email = change_email_form.email.data.lower().strip()
|
||||||
if new_email != mailbox.email and not pending_email:
|
if new_email != mailbox.email and not pending_email:
|
||||||
# check if this email is not already used
|
# check if this email is not already used
|
||||||
if (
|
if mailbox_already_used(new_email, current_user) or Alias.get_by(
|
||||||
mailbox_already_used(new_email, current_user)
|
email=new_email
|
||||||
or Alias.get_by(email=new_email)
|
|
||||||
):
|
):
|
||||||
flash(f"Email {new_email} already used", "error")
|
flash(f"Email {new_email} already used", "error")
|
||||||
elif not email_domain_can_be_used_as_mailbox(new_email):
|
elif not email_domain_can_be_used_as_mailbox(new_email):
|
||||||
|
|
Loading…
Reference in a new issue