Code Duplication    Length = 7-8 lines in 2 locations

class.jetpack-options.php 2 locations

@@ 200-206 (lines=7) @@
197
	 * @return mixed
198
	 */
199
	public static function get_option( $name, $default = false ) {
200
		if ( self::is_valid( $name, 'non_compact' ) ) {
201
			if ( self::is_network_option( $name ) ) {
202
				return get_site_option( "jetpack_$name", $default );
203
			}
204
205
			return get_option( "jetpack_$name", $default );
206
		}
207
208
		foreach ( array_keys( self::$grouped_options ) as $group ) {
209
			if ( self::is_valid( $name, $group ) ) {
@@ 277-284 (lines=8) @@
274
		 * @param mixed $value The new value of the option.
275
		 */
276
		do_action( 'pre_update_jetpack_option_' . $name, $name, $value );
277
		if ( self::is_valid( $name, 'non_compact' ) ) {
278
			if ( self::is_network_option( $name ) ) {
279
				return update_site_option( "jetpack_$name", $value );
280
			}
281
282
			return update_option( "jetpack_$name", $value, $autoload );
283
284
		}
285
286
		foreach ( array_keys( self::$grouped_options ) as $group ) {
287
			if ( self::is_valid( $name, $group ) ) {