Code Duplication    Length = 6-6 lines in 2 locations

view/Requirements.php 2 locations

@@ 802-807 (lines=6) @@
799
			// Combine files - updates $this->javascript and $this->css
800
			$this->process_combined_files();
801
802
			foreach(array_diff_key($this->javascript,$this->blocked) as $file => $dummy) {
803
				$path = Convert::raw2xml($this->path_for_file($file));
804
				if($path) {
805
					$jsRequirements .= "<script type=\"text/javascript\" src=\"$path\"></script>\n";
806
				}
807
			}
808
809
			// Add all inline JavaScript *after* including external files they might rely on
810
			if($this->customScript) {
@@ 892-897 (lines=6) @@
889
		$jsRequirements = array();
890
		$cssRequirements = array();
891
892
		foreach(array_diff_key($this->javascript, $this->blocked) as $file => $dummy) {
893
			$path = $this->path_for_file($file);
894
			if($path) {
895
				$jsRequirements[] = str_replace(',', '%2C', $path);
896
			}
897
		}
898
899
		$response->addHeader('X-Include-JS', implode(',', $jsRequirements));
900