From 36579b774fa0c4454b4e2f53623a5873e66a83bd Mon Sep 17 00:00:00 2001 From: Krzysztof Kotlarek Date: Mon, 27 Jul 2020 12:04:28 +1000 Subject: [PATCH] FIX: check if add_post_custom_fields_allowlister exisits --- plugin.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/plugin.rb b/plugin.rb index 1f5a2b5..0d727d1 100644 --- a/plugin.rb +++ b/plugin.rb @@ -251,12 +251,12 @@ SQL end # TODO Drop after Discourse 2.6.0 release - if TopicView.respond_to?(:add_post_custom_fields_whitelister) - TopicView.add_post_custom_fields_whitelister do |user| + if TopicView.respond_to?(:add_post_custom_fields_allowlister) + TopicView.add_post_custom_fields_allowlister do |user| ["is_accepted_answer"] end else - TopicView.add_post_custom_fields_allowlister do |user| + TopicView.add_post_custom_fields_whitelister do |user| ["is_accepted_answer"] end end