Code Duplication    Length = 5-5 lines in 2 locations

class.jetpack-gutenberg.php 2 locations

@@ 457-461 (lines=5) @@
454
455
		// Enqueue styles.
456
		$style_relative_path = self::get_blocks_directory() . $type . '/view' . ( is_rtl() ? '.rtl' : '' ) . '.css';
457
		if ( self::block_has_asset( $style_relative_path ) ) {
458
			$style_version = self::get_asset_version( $style_relative_path );
459
			$view_style    = plugins_url( $style_relative_path, JETPACK__PLUGIN_FILE );
460
			wp_enqueue_style( 'jetpack-block-' . $type, $view_style, array(), $style_version );
461
		}
462
463
	}
464
	/**
@@ 480-484 (lines=5) @@
477
478
		// Enqueue script.
479
		$script_relative_path = self::get_blocks_directory() . $type . '/view.js';
480
		if ( self::block_has_asset( $script_relative_path ) ) {
481
			$script_version = self::get_asset_version( $script_relative_path );
482
			$view_script    = plugins_url( $script_relative_path, JETPACK__PLUGIN_FILE );
483
			wp_enqueue_script( 'jetpack-block-' . $type, $view_script, $script_dependencies, $script_version, false );
484
		}
485
486
		wp_localize_script(
487
			'jetpack-block-' . $type,