Code Duplication    Length = 7-7 lines in 3 locations

_inc/lib/core-api/class.jetpack-core-api-module-endpoints.php 3 locations

@@ 745-751 (lines=7) @@
742
				case 'google':
743
				case 'bing':
744
				case 'pinterest':
745
				case 'yandex':
746
					$grouped_options          = $grouped_options_current = (array) get_option( 'verification_services_codes' );
747
					$grouped_options[$option] = $value;
748
749
					// If option value was the same, consider it done.
750
					$updated = $grouped_options_current != $grouped_options ? update_option( 'verification_services_codes', $grouped_options ) : true;
751
					break;
752
753
				case 'sharing_services':
754
					if ( ! class_exists( 'Sharing_Service' ) && ! include_once( JETPACK__PLUGIN_DIR . 'modules/sharedaddy/sharing-service.php' ) ) {
@@ 865-871 (lines=7) @@
862
				case 'blog_id':
863
				case 'do_not_track':
864
				case 'hide_smile':
865
				case 'version':
866
					$grouped_options          = $grouped_options_current = (array) get_option( 'stats_options' );
867
					$grouped_options[$option] = $value;
868
869
					// If option value was the same, consider it done.
870
					$updated = $grouped_options_current != $grouped_options ? update_option( 'stats_options', $grouped_options ) : true;
871
					break;
872
873
				case Jetpack_Core_Json_Api_Endpoints::holiday_snow_option_name():
874
					$updated = get_option( $option ) != $value ? update_option( $option, (bool) $value ? 'letitsnow' : '' ) : true;
@@ 928-934 (lines=7) @@
925
					$updated = false;
926
					break;
927
928
				case 'google_analytics_tracking_id':
929
					$grouped_options = $grouped_options_current = (array) get_option( 'jetpack_wga' );
930
					$grouped_options[ 'code' ] = $value;
931
932
					// If option value was the same, consider it done.
933
					$updated = $grouped_options_current != $grouped_options ? update_option( 'jetpack_wga', $grouped_options ) : true;
934
					break;
935
936
				case 'dismiss_dash_app_card':
937
				case 'dismiss_empty_stats_card':