mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
FIX: use a custom prefix for custom flags (#28839)
Currently, when the custom flag has the same name as the system flag (which is disabled) then it is not displayed. To fix the problem, `custom_` prefix as `name_key` is used to distinguish between the system and the custom flag. I considered writing a migration to fix existing custom flags name key. However, at the end of migration I would need to run rails code to reset cache `Flag.reset_flag_settings!`. I decided to skip that step as it is a very edge case. If someone has the same flag name as the system flag, then all they have to do is edit the flag and click save. In addition, I made 2 small fixes: - edit flag title was missing translation; - flag form UI was not showing that description is the required field.
This commit is contained in:
committed by
GitHub
parent
0323b366f3
commit
1f1709d249
@@ -5617,6 +5617,7 @@ en:
|
||||
saved: "saved!"
|
||||
flags:
|
||||
header: "Moderation Flags"
|
||||
edit_header: "Edit Flag"
|
||||
subheader: "The flagging system in Discourse helps you and your moderator team manage content and user behavior, keeping your community respectful and healthy. The defaults are suitable for most communities and you don’t have to change them. However, if your site has particular requirements you can disable flags you don’t need and add your own custom flags."
|
||||
description: "Description"
|
||||
enabled: "Enabled?"
|
||||
|
||||
Reference in New Issue
Block a user