Code Duplication    Length = 5-5 lines in 2 locations

class.jetpack-gutenberg.php 2 locations

@@ 117-121 (lines=5) @@
114
		$type = sanitize_title_with_dashes( $type );
115
		// Enqueue styles.
116
		$style_relative_path = '_inc/blocks/' . $type . '/view' . ( is_rtl() ? '.rtl' : '' ) . '.css';
117
		if ( self::block_has_asset( $style_relative_path ) ) {
118
			$style_version = self::get_asset_version( $style_relative_path );
119
			$view_style    = plugins_url( $style_relative_path, JETPACK__PLUGIN_FILE );
120
			wp_enqueue_style( 'jetpack-block-' . $type, $view_style, array(), $style_version );
121
		}
122
123
		// Enqueue script.
124
		$script_relative_path = '_inc/blocks/' . $type . '/view.js';
@@ 125-129 (lines=5) @@
122
123
		// Enqueue script.
124
		$script_relative_path = '_inc/blocks/' . $type . '/view.js';
125
		if ( self::block_has_asset( $script_relative_path ) ) {
126
			$script_version = self::get_asset_version( $script_relative_path );
127
			$view_script    = plugins_url( $script_relative_path, JETPACK__PLUGIN_FILE );
128
			wp_enqueue_script( 'jetpack-block-' . $type, $view_script, $script_dependencies, $script_version, false );
129
		}
130
	}
131
132
	/**