mirror of
https://gh.wpcy.net/https://github.com/discourse/discourse.git
synced 2026-05-06 21:30:25 +08:00
`UserNotifications#account_deleted` builds a localized flag reason from the reviewable’s first `reviewable_score` (falling back to `spam` if none is found). Currently, some score types (e.g. `needs_approval`) are not covered. In cases where a "Needs Approval" flag led to an account deletion, the lookup key could end up as `flag_reasons.`, causing the entire `flag_reasons` section to be rendered instead of a single entry. This change adds support for additional score types (like `needs_approval`). If no translation exists (e.g. custom flags), the flag’s description will be used if available, before falling back to the default `spam` reason. More context: https://meta.discourse.org/t/ruby-hash-syntax-being-displayed-in-emails-sent-to-deleted-users/382411 |
||
|---|---|---|
| .. | ||
| group_smtp_mailer_spec.rb | ||
| invite_mailer_spec.rb | ||
| rejection_mailer_spec.rb | ||
| subscription_mailer_spec.rb | ||
| test_mailer_spec.rb | ||
| user_notifications_spec.rb | ||
| version_mailer_spec.rb | ||