FIX: Use Topic#url to generate topic URL

FIX: Use Topic#url to generate topic URL

diff --git a/app/mailers/assign_mailer.rb b/app/mailers/assign_mailer.rb
index 09b5dc1..7d89575 100644
--- a/app/mailers/assign_mailer.rb
+++ b/app/mailers/assign_mailer.rb
@@ -17,7 +17,7 @@ class AssignMailer < ActionMailer::Base
       topic_title: topic.title,
       assignee_name: assigned_by.username,
       topic_excerpt: topic.excerpt,
-      topic_link: "#{Discourse.base_url}/t/#{topic.slug}"
+      topic_link: topic.url
     }
     build_email(to_address, opts)
   end

GitHub sha: 6825dcd0

1 Like