Code Duplication    Length = 7-8 lines in 10 locations

modules/sharedaddy/sharing-sources.php 10 locations

@@ 360-367 (lines=8) @@
357
class Share_Email extends Sharing_Source {
358
	public $shortname = 'email';
359
	public $genericon = '\f410';
360
	public function __construct( $id, array $settings ) {
361
		parent::__construct( $id, $settings );
362
363
		if ( 'official' == $this->button_style )
364
			$this->smart = true;
365
		else
366
			$this->smart = false;
367
	}
368
369
	public function get_name() {
370
		return _x( 'Email', 'as sharing source', 'jetpack' );
@@ 542-549 (lines=8) @@
539
	// 'https://dev.twitter.com/rest/reference/get/help/configuration' ( 2015/02/06 ) short_url_length is 22, short_url_length_https is 23
540
	public $short_url_length = 24;
541
542
	public function __construct( $id, array $settings ) {
543
		parent::__construct( $id, $settings );
544
545
		if ( 'official' == $this->button_style )
546
			$this->smart = true;
547
		else
548
			$this->smart = false;
549
	}
550
551
	public function get_name() {
552
		return __( 'Twitter', 'jetpack' );
@@ 735-742 (lines=8) @@
732
class Share_Reddit extends Sharing_Source {
733
	public $shortname = 'reddit';
734
	public $genericon = '\f222';
735
	public function __construct( $id, array $settings ) {
736
		parent::__construct( $id, $settings );
737
738
		if ( 'official' == $this->button_style )
739
			$this->smart = true;
740
		else
741
			$this->smart = false;
742
	}
743
744
	public function get_name() {
745
		return __( 'Reddit', 'jetpack' );
@@ 770-777 (lines=8) @@
767
class Share_LinkedIn extends Sharing_Source {
768
	public $shortname = 'linkedin';
769
	public $genericon = '\f207';
770
	public function __construct( $id, array $settings ) {
771
		parent::__construct( $id, $settings );
772
773
		if ( 'official' == $this->button_style )
774
			$this->smart = true;
775
		else
776
			$this->smart = false;
777
	}
778
779
	public function get_name() {
780
		return __( 'LinkedIn', 'jetpack' );
@@ 979-986 (lines=8) @@
976
class Share_Print extends Sharing_Source {
977
	public $shortname = 'print';
978
	public $genericon = '\f469';
979
	public function __construct( $id, array $settings ) {
980
		parent::__construct( $id, $settings );
981
982
		if ( 'official' == $this->button_style )
983
			$this->smart = true;
984
		else
985
			$this->smart = false;
986
	}
987
988
	public function get_name() {
989
		return __( 'Print', 'jetpack' );
@@ 1000-1007 (lines=8) @@
997
class Share_PressThis extends Sharing_Source {
998
	public $shortname = 'pressthis';
999
	public $genericon = '\f205';
1000
	public function __construct( $id, array $settings ) {
1001
		parent::__construct( $id, $settings );
1002
1003
		if ( 'official' == $this->button_style )
1004
			$this->smart = true;
1005
		else
1006
			$this->smart = false;
1007
	}
1008
1009
	public function get_name() {
1010
		return __( 'Press This', 'jetpack' );
@@ 1064-1071 (lines=8) @@
1061
	public $genericon = '\f218';
1062
	private $state = false;
1063
1064
	public function __construct( $id, array $settings ) {
1065
		parent::__construct( $id, $settings );
1066
1067
		if ( 'official' == $this->button_style )
1068
			$this->smart = true;
1069
		else
1070
			$this->smart = false;
1071
	}
1072
1073
	public function get_name() {
1074
		return __( 'Google', 'jetpack' );
@@ 1350-1356 (lines=7) @@
1347
class Share_Tumblr extends Sharing_Source {
1348
	public $shortname = 'tumblr';
1349
	public $genericon = '\f214';
1350
	public function __construct( $id, array $settings ) {
1351
		parent::__construct( $id, $settings );
1352
		if ( 'official' == $this->button_style )
1353
			$this->smart = true;
1354
		else
1355
			$this->smart = false;
1356
	}
1357
1358
	public function get_name() {
1359
		return __( 'Tumblr', 'jetpack' );
@@ 1397-1403 (lines=7) @@
1394
	public $shortname = 'pinterest';
1395
	public $genericon = '\f209';
1396
1397
	public function __construct( $id, array $settings ) {
1398
		parent::__construct( $id, $settings );
1399
		if ( 'official' == $this->button_style )
1400
			$this->smart = true;
1401
		else
1402
			$this->smart = false;
1403
	}
1404
1405
	public function get_name() {
1406
		return __( 'Pinterest', 'jetpack' );
@@ 1546-1553 (lines=8) @@
1543
	public $shortname = 'pocket';
1544
	public $genericon = '\f224';
1545
1546
	public function __construct( $id, array $settings ) {
1547
		parent::__construct( $id, $settings );
1548
1549
		if ( 'official' == $this->button_style )
1550
			$this->smart = true;
1551
		else
1552
			$this->smart = false;
1553
	}
1554
1555
	public function get_name() {
1556
		return __( 'Pocket', 'jetpack' );