Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: pick drupal host during password reset #451

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion openedx/core/djangoapps/user_authn/views/password_reset.py
Original file line number Diff line number Diff line change
Expand Up @@ -149,8 +149,12 @@ def send_password_reset_email_for_user(user, request, preferred_email=None):
preferred_email (str): Send email to this address if present, otherwise fallback to user's email address.
"""
message_context, user_language_preference = get_user_default_email_params(user)
site_name = settings.AUTHN_MICROFRONTEND_DOMAIN if should_redirect_to_authn_microfrontend() \
site_name = (
configuration_helpers.get_value('DRUPAL_HOST', settings.DRUPAL_HOST)
or settings.AUTHN_MICROFRONTEND_DOMAIN
if should_redirect_to_authn_microfrontend()
else configuration_helpers.get_value('SITE_NAME', settings.SITE_NAME)
)
message_context.update({
'request': request, # Used by google_analytics_tracking_pixel
# TODO: This overrides `platform_name` from `get_base_template_context` to make the tests passes
Expand Down
Loading