Code Duplication    Length = 12-14 lines in 3 locations

modules/widgets/blog-stats.php 1 location

@@ 29-42 (lines=14) @@
26
	/**
27
	 * Constructor
28
	 */
29
	function __construct() {
30
		$widget_ops = array(
31
			'classname' => 'blog-stats',
32
			'description' => esc_html__( 'Show a hit counter for your blog.', 'jetpack' ),
33
			'customize_selective_refresh' => true,
34
		);
35
		parent::__construct(
36
			'blog-stats',
37
			/** This filter is documented in modules/widgets/facebook-likebox.php */
38
			apply_filters( 'jetpack_widget_name', esc_html__( 'Blog Stats', 'jetpack' ) ),
39
			$widget_ops
40
		);
41
		$this->alt_option_name = 'widget_statscounter';
42
	}
43
44
	/**
45
	 * Return an associative array of default values

modules/widgets/rsslinks-widget.php 1 location

@@ 11-23 (lines=13) @@
8
9
class Jetpack_RSS_Links_Widget extends WP_Widget {
10
11
	function __construct() {
12
		$widget_ops = array(
13
			'classname' => 'widget_rss_links',
14
			'description' => __( "Links to your blog's RSS feeds", 'jetpack' ),
15
			'customize_selective_refresh' => true,
16
		);
17
		parent::__construct(
18
			'rss_links',
19
			/** This filter is documented in modules/widgets/facebook-likebox.php */
20
			apply_filters( 'jetpack_widget_name', __( 'RSS Links', 'jetpack' ) ),
21
			$widget_ops
22
		);
23
	}
24
25
	function widget( $args, $instance ) {
26
		$instance = wp_parse_args( (array) $instance, $this->defaults() );

modules/widgets/mailchimp.php 1 location

@@ 22-33 (lines=12) @@
19
		/**
20
		 * Constructor
21
		 */
22
		function __construct() {
23
			parent::__construct(
24
				'widget_mailchimp_subscriber_popup',
25
				/** This filter is documented in modules/widgets/facebook-likebox.php */
26
				apply_filters( 'jetpack_widget_name', __( 'MailChimp Subscriber Popup', 'jetpack' ) ),
27
				array(
28
					'classname'                   => 'widget_mailchimp_subscriber_popup',
29
					'description'                 => __( 'Allows displaying a popup subscription form to visitors.', 'jetpack' ),
30
					'customize_selective_refresh' => true,
31
				)
32
			);
33
		}
34
35
		/**
36
		 * Outputs the HTML for this widget.