Code Duplication    Length = 11-12 lines in 2 locations

geodirectory-widgets/geodirectory_bestof_widget.php 1 location

@@ 136-147 (lines=12) @@
133
            }
134
        }
135
136
        if (isset($instance['character_count'])) {
137
            /**
138
             * Filter the widget's excerpt character count.
139
             *
140
             * @since 1.3.9
141
             *
142
             * @param int $instance ['character_count'] Excerpt character count.
143
             */
144
            $character_count = apply_filters('bestof_widget_list_character_count', $instance['character_count']);
145
        } else {
146
            $character_count = '';
147
        }
148
149
        $category_taxonomy = geodir_get_taxonomies($post_type);
150

geodirectory-functions/general_functions.php 1 location

@@ 3203-3213 (lines=11) @@
3200
    $title = str_replace("%posttype_plural_label%", $posttype_plural_label, $title);
3201
    $title = str_replace("%posttype_singular_label%", $posttype_singular_label, $title);
3202
3203
    if (isset($instance['character_count'])) {
3204
        /**
3205
         * Filter the widget's excerpt character count.
3206
         *
3207
         * @since 1.0.0
3208
         * @param int $instance['character_count'] Excerpt character count.
3209
         */
3210
        $character_count = apply_filters('widget_list_character_count', $instance['character_count']);
3211
    } else {
3212
        $character_count = '';
3213
    }
3214
3215
    if (empty($title) || $title == 'All') {
3216
        $title .= ' ' . __(get_post_type_plural_label($post_type), 'geodirectory');