Projet

Général

Profil

0001-emails-always-provide-a-site-variable-32789.patch

Frédéric Péters, 05 mai 2019 16:11

Télécharger (1,19 ko)

Voir les différences:

Subject: [PATCH] emails: always provide a site variable (#32789)

 src/authentic2/utils.py | 2 ++
 1 file changed, 2 insertions(+)
src/authentic2/utils.py
758 758
        'user': user,
759 759
        'email': user.email,
760 760
        'expiration_days': settings.PASSWORD_RESET_TIMEOUT_DAYS,
761
        'site': request.get_host() if request else '',
761 762
    })
762 763

  
763 764
    # Build reset URL
......
1062 1063
        'old_email': user.email,
1063 1064
        'user': user,
1064 1065
        'link': link,
1066
        'site': request.get_host(),
1065 1067
        'domain': request.get_host(),
1066 1068
        'token_lifetime': human_duration(app_settings.A2_EMAIL_CHANGE_TOKEN_LIFETIME),
1067 1069
        'password_reset_url': request.build_absolute_uri(reverse('password_reset')),
1068
-