Code Duplication    Length = 10-10 lines in 2 locations

class.jetpack-sync-functions.php 1 location

@@ 32-41 (lines=10) @@
29
		return array();
30
	}
31
32
	static function sync_all( $values = null, $check_sum = null ) {
33
		if ( is_null( $values ) ) {
34
			$values           = self::values( self::$functions );
35
		}
36
		if( is_null( $check_sum ) ) {
37
			$check_sum = self::get_check_sum( $values );
38
		}
39
		Jetpack_Options::update_option( 'function_check_sum', $check_sum );
40
		return $values;
41
	}
42
43
	static function get_check_sum( $values = null ) {
44
		if( is_null( $values ) ){

class.jetpack-sync-options.php 1 location

@@ 63-72 (lines=10) @@
60
		return null;
61
	}
62
63
	static function sync_all( $values = null, $check_sum = null ) {
64
		if ( is_null( $values ) ) {
65
			$values           = self::values( self::$options );
66
		}
67
		if( is_null( $check_sum ) ) {
68
			$check_sum = self::get_check_sum( $values );
69
		}
70
		Jetpack_Options::update_option( 'options_check_sum', $check_sum );
71
		return $values;
72
	}
73
74
	static function options_to_sync() {
75
		return array_unique( self::$sync );