Code Duplication    Length = 7-8 lines in 9 locations

modules/sharedaddy/sharing-sources.php 9 locations

@@ 444-451 (lines=8) @@
441
class Share_Email extends Sharing_Source {
442
	public $shortname = 'email';
443
	public $icon = '\f410';
444
	public function __construct( $id, array $settings ) {
445
		parent::__construct( $id, $settings );
446
447
		if ( 'official' == $this->button_style ) {
448
			$this->smart = true;
449
		} else {
450
			$this->smart = false;
451
		}
452
	}
453
454
	public function get_name() {
@@ 631-638 (lines=8) @@
628
	// 'https://dev.twitter.com/rest/reference/get/help/configuration' ( 2015/02/06 ) short_url_length is 22, short_url_length_https is 23
629
	public $short_url_length = 24;
630
631
	public function __construct( $id, array $settings ) {
632
		parent::__construct( $id, $settings );
633
634
		if ( 'official' == $this->button_style ) {
635
			$this->smart = true;
636
		} else {
637
			$this->smart = false;
638
		}
639
	}
640
641
	public function get_name() {
@@ 845-852 (lines=8) @@
842
class Share_Reddit extends Sharing_Source {
843
	public $shortname = 'reddit';
844
	public $icon = '\f222';
845
	public function __construct( $id, array $settings ) {
846
		parent::__construct( $id, $settings );
847
848
		if ( 'official' == $this->button_style ) {
849
			$this->smart = true;
850
		} else {
851
			$this->smart = false;
852
		}
853
	}
854
855
	public function get_name() {
@@ 882-889 (lines=8) @@
879
class Share_LinkedIn extends Sharing_Source {
880
	public $shortname = 'linkedin';
881
	public $icon = '\f207';
882
	public function __construct( $id, array $settings ) {
883
		parent::__construct( $id, $settings );
884
885
		if ( 'official' == $this->button_style ) {
886
			$this->smart = true;
887
		} else {
888
			$this->smart = false;
889
		}
890
	}
891
892
	public function get_name() {
@@ 1093-1100 (lines=8) @@
1090
class Share_Print extends Sharing_Source {
1091
	public $shortname = 'print';
1092
	public $icon = '\f469';
1093
	public function __construct( $id, array $settings ) {
1094
		parent::__construct( $id, $settings );
1095
1096
		if ( 'official' == $this->button_style ) {
1097
			$this->smart = true;
1098
		} else {
1099
			$this->smart = false;
1100
		}
1101
	}
1102
1103
	public function get_name() {
@@ 1115-1122 (lines=8) @@
1112
class Share_PressThis extends Sharing_Source {
1113
	public $shortname = 'pressthis';
1114
	public $icon = '\f205';
1115
	public function __construct( $id, array $settings ) {
1116
		parent::__construct( $id, $settings );
1117
1118
		if ( 'official' == $this->button_style ) {
1119
			$this->smart = true;
1120
		} else {
1121
			$this->smart = false;
1122
		}
1123
	}
1124
1125
	public function get_name() {
@@ 1386-1393 (lines=8) @@
1383
class Share_Tumblr extends Sharing_Source {
1384
	public $shortname = 'tumblr';
1385
	public $icon = '\f214';
1386
	public function __construct( $id, array $settings ) {
1387
		parent::__construct( $id, $settings );
1388
		if ( 'official' == $this->button_style ) {
1389
			$this->smart = true;
1390
		} else {
1391
			$this->smart = false;
1392
		}
1393
	}
1394
1395
	public function get_name() {
1396
		return __( 'Tumblr', 'jetpack' );
@@ 1456-1462 (lines=7) @@
1453
	public $shortname = 'pinterest';
1454
	public $icon = '\f209';
1455
1456
	public function __construct( $id, array $settings ) {
1457
		parent::__construct( $id, $settings );
1458
		if ( 'official' == $this->button_style ) {
1459
			$this->smart = true;
1460
		} else {
1461
			$this->smart = false;
1462
		}
1463
	}
1464
1465
	public function get_name() {
@@ 1608-1614 (lines=7) @@
1605
	public $shortname = 'pocket';
1606
	public $icon = '\f224';
1607
1608
	public function __construct( $id, array $settings ) {
1609
		parent::__construct( $id, $settings );
1610
1611
		if ( 'official' == $this->button_style ) {
1612
			$this->smart = true;
1613
		} else {
1614
			$this->smart = false;
1615
		}
1616
	}
1617