From 4d7e14bc0cc6fae89757737767c31caed5d9a649 Mon Sep 17 00:00:00 2001 From: James Burke Date: Fri, 24 Sep 2021 17:45:16 +0100 Subject: [PATCH 1/2] Add coral comment count threshold setting --- inc/integrations/class-coral.php | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/inc/integrations/class-coral.php b/inc/integrations/class-coral.php index ad7676a0..1572e06d 100644 --- a/inc/integrations/class-coral.php +++ b/inc/integrations/class-coral.php @@ -137,6 +137,14 @@ public function register_settings_fields() { 'irving_integrations_settings' ); + add_settings_field( + 'wp_irving_coral_comment_count_display_threshold', + esc_html__( 'Minimum number of comments required to display the comment count', 'wp-irving' ), + [ $this, 'render_coral_comment_count_display_threshold_input' ], + 'wp_irving_integrations', + 'irving_integrations_settings' + ); + add_settings_field( 'wp_irving_coral_banned_names', esc_html__( 'Coral Banned Username Values', 'wp-irving' ), @@ -220,6 +228,18 @@ public function render_coral_use_cron_input() { options[ $this->option_key ]['comment_count_display_threshold'] ?? 0; + + ?> + + Date: Mon, 27 Sep 2021 15:44:19 +0100 Subject: [PATCH 2/2] Update inc/integrations/class-coral.php Co-authored-by: Amy Evans --- inc/integrations/class-coral.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inc/integrations/class-coral.php b/inc/integrations/class-coral.php index 1572e06d..668e87b8 100644 --- a/inc/integrations/class-coral.php +++ b/inc/integrations/class-coral.php @@ -232,7 +232,7 @@ public function render_coral_use_cron_input() { * Render a number input which determines when comment count icons appear. */ public function render_coral_comment_count_display_threshold_input() { - // Check to see if there is an existing SSO secret in the option. + // Check to see if there is an existing value. $comment_count_display_threshold = $this->options[ $this->option_key ]['comment_count_display_threshold'] ?? 0; ?>