pfaffman
(Jay Pfaffman)
September 16, 2020, 2:50pm
8
Thanks, Arpit. These people (whose installation I’m not managing) are on 2.5.0. Can you help me understand where confirm_admin_url
gets defined so that I can confirm that it’s a bug in their version of Discourse?
This is on 2.5.0.
The admin confirmation URL in the email has subfolder duplicated. like
https://www.example.com/subfolder/subfolder/u/confirm-admin/key.
I’m looking at
https://github.com/discourse/discourse/blob/master/app/mailers/admin_confirmation_mailer.rb#L12
it appears to call something called confirm_admin_url, but I can’t find where that’s defined.
I’m not sure where to look to see if it’s a bug or some configuration issue (but this is the only place this problem is showing up).
class AdminConfirmationMailer < ActionMailer::Base
include Email::BuildEmailHelper
def send_email(to_address, target_email, target_username, token)
build_email(
to_address,
template: "admin_confirmation_mailer",
target_email: target_email,
target_username: target_username,
admin_confirm_url: confirm_admin_url(token: token, host: Discourse.base_url),
)
end
end
Thanks.
1 Like