diff --git a/app/mailers/user_notifications.rb b/app/mailers/user_notifications.rb index c7c3832e4c2..4b9ffa27253 100644 --- a/app/mailers/user_notifications.rb +++ b/app/mailers/user_notifications.rb @@ -333,7 +333,7 @@ class UserNotifications < ActionMailer::Base invite_template = "user_notifications.invited_to_topic_body" end topic_excerpt = post.excerpt.gsub("\n", " ") if post.is_first_post? && post.excerpt - message = I18n.t(invite_template, username: post.username, topic_title: title, topic_excerpt: topic_excerpt, site_title: SiteSetting.title, site_description: SiteSetting.site_description) + message = I18n.t(invite_template, username: username, topic_title: title, topic_excerpt: topic_excerpt, site_title: SiteSetting.title, site_description: SiteSetting.site_description) html = UserNotificationRenderer.new(Rails.configuration.paths["app/views"]).render( template: 'email/invite', format: :html,