Code Duplication    Length = 5-5 lines in 2 locations

modules/perf/class.jetpack-perf-optimize-assets.php 2 locations

@@ 603-607 (lines=5) @@
600
	 public function register_inline_script( $handle, $file, $plugin_file, $deps = false, $ver = false, $in_footer = false ) {
601
		$registered = wp_register_script( $handle, plugins_url( $file, $plugin_file ), $deps, $ver, $in_footer );
602
603
		if ( $registered ) {
604
			$file_full_path = dirname( $plugin_file ) . '/' . $file;
605
			wp_script_add_data( $handle, 'jetpack-inline', true );
606
			wp_script_add_data( $handle, 'jetpack-inline-file', $file_full_path );
607
		}
608
609
		return $registered;
610
	}
@@ 620-624 (lines=5) @@
617
	public function register_inline_style( $handle, $file, $plugin_file, $deps = array(), $ver = false, $media = 'all' ) {
618
		$registered = wp_register_style( $handle, plugins_url( $file, $plugin_file ), $deps, $ver, $media );
619
620
		if ( $registered ) {
621
			$file_full_path = dirname( $plugin_file ) . '/' . $file;
622
			wp_style_add_data( $handle, 'jetpack-inline', true );
623
			wp_style_add_data( $handle, 'jetpack-inline-file', $file_full_path );
624
		}
625
	}
626
}
627