Merge pull request #2069 from willmendesneto/develop

Minify output in css and javascript code
diff --git a/system/core/Output.php b/system/core/Output.php
index 98deff5..2e239c7 100644
--- a/system/core/Output.php
+++ b/system/core/Output.php
@@ -780,6 +780,7 @@
 			break;
 
 			case 'text/css':
+			case 'text/javascript':
 
 				//Remove CSS comments
 				$output = preg_replace('!/\*[^*]*\*+([^/][^*]*\*+)*/!', '', $output);
@@ -788,11 +789,12 @@
 				// semi-colons, parenthesis, commas
 				$output = preg_replace('!\s*(:|;|,|}|{|\(|\))\s*!', '$1', $output);
 
-			break;
+				// Remove spaces
+			        $output =  preg_replace('/  /s', ' ', $output);
 
-			case 'text/javascript':
+			        // Remove breaklines and tabs
+			        $output =  preg_replace('/[\r\n\t]/', '', $output);
 
-				// Currently leaves JavaScript untouched.
 			break;
 
 			default: break;
@@ -804,4 +806,4 @@
 }
 
 /* End of file Output.php */
-/* Location: ./system/core/Output.php */
\ No newline at end of file
+/* Location: ./system/core/Output.php */