FIX: Link to group didn't work in locales other than English (#30237)

Group names are translated, so the slug changes depending on the default locale. This could break the link to the staff group.
This commit is contained in:
Gerhard Schlager
2024-12-12 13:26:51 +01:00
committed by GitHub
parent 35ee746a14
commit c357e621ef
3 changed files with 9 additions and 3 deletions

View File

@ -568,7 +568,7 @@ module DiscourseNarrativeBot
return unless @post.user.id == -2
raw = <<~MD
#{I18n.t("#{I18N_KEY}.flag.reply", i18n_post_args)}
#{I18n.t("#{I18N_KEY}.flag.reply", i18n_post_args(group_url: Group.find(Group::AUTO_GROUPS[:staff]).full_url))}
#{instance_eval(&@next_instructions)}
MD