mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
DEV: Namespace chat_header_indicator UserOption enum (#22152)
Previously this was defining methods like `UserOption#never?`, `UserOption#all_new?`, `UserOption#dm_and_mentions?`. Now they will be prefixed like `UserOption#chat_header_indicator_never?`
This commit is contained in:
@@ -22,8 +22,10 @@ module Chat
|
||||
base.enum :chat_email_frequency, base.chat_email_frequencies, prefix: "send_chat_email"
|
||||
end
|
||||
|
||||
if !base.method_defined?(:never?) # Avoid attempting to override when autoloading
|
||||
base.enum :chat_header_indicator_preference, base.chat_header_indicator_preferences
|
||||
if !base.method_defined?(:chat_header_indicator_never?) # Avoid attempting to override when autoloading
|
||||
base.enum :chat_header_indicator_preference,
|
||||
base.chat_header_indicator_preferences,
|
||||
prefix: "chat_header_indicator"
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user