Commit 7bb62daf authored by chirac's avatar chirac Committed by Maël Kervella

Fix compte mail , get_mail si redirection

parent bf189f4c
......@@ -679,10 +679,10 @@ class User(RevMixin, FieldPermissionModelMixin, AbstractBaseUser,
Return the mail address choosen by the user
if not OptionalUser.get_cached_value('mail_accounts') or not self.internal_address:
return self.external_mail
if not OptionalUser.get_cached_value('mail_accounts') or not self.internal_address or self.redirection:
return str(self.external_mail)
return self.mail.mailalias_set.get(valeur=self.pseudo)
return str(self.mailalias_set.get(valeur=self.pseudo))
def get_next_domain_name(self):
"""Look for an available name for a new interface for
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment