DEV: Remove deprecated whitelist methods (#22731)

These methods were deprecated and marked for removal in 2.6. This change deletes them.

These deprecations use raise_error: true, so the fallbacks are at this point unreachable and can't be used anyway.
This commit is contained in:
Ted Johansson
2023-07-21 11:32:21 +08:00
committed by GitHub
parent a5c0b87d25
commit 4ef8129bff
2 changed files with 0 additions and 68 deletions

View File

@ -189,28 +189,10 @@ class Plugin::Instance
end
end
def whitelist_staff_user_custom_field(field)
Discourse.deprecate(
"whitelist_staff_user_custom_field is deprecated, use the allow_staff_user_custom_field.",
drop_from: "2.6",
raise_error: true,
)
allow_staff_user_custom_field(field)
end
def allow_staff_user_custom_field(field)
DiscoursePluginRegistry.register_staff_user_custom_field(field, self)
end
def whitelist_public_user_custom_field(field)
Discourse.deprecate(
"whitelist_public_user_custom_field is deprecated, use the allow_public_user_custom_field.",
drop_from: "2.6",
raise_error: true,
)
allow_public_user_custom_field(field)
end
def allow_public_user_custom_field(field)
DiscoursePluginRegistry.register_public_user_custom_field(field, self)
end
@ -378,15 +360,6 @@ class Plugin::Instance
end
end
def topic_view_post_custom_fields_whitelister(&block)
Discourse.deprecate(
"topic_view_post_custom_fields_whitelister is deprecated, use the topic_view_post_custom_fields_allowlister.",
drop_from: "2.6",
raise_error: true,
)
topic_view_post_custom_fields_allowlister(&block)
end
# Add a post_custom_fields_allowlister block to the TopicView, respecting if the plugin is enabled
def topic_view_post_custom_fields_allowlister(&block)
reloadable_patch do |plugin|