JSDOC/Packer.js
[gnome.introspection-doc-generator] / JSDOC / Packer.js
index a4ec80e..6bd8cf2 100644 (file)
@@ -280,16 +280,12 @@ Packer.prototype = {
             }
             var str = File.read(file);
             var str = this.pack(str, file, minfile);
-            
-            
-            if (str.length) {
-                File.write(minfile, str);
-            }
-            
              
           
         }
         
+        
+        
         // if we are translating, write the translations strings at the top
         // of the file..
         
@@ -419,15 +415,15 @@ Packer.prototype = {
         sp.mungeSymboltree();
         this.timerPrint("Munged Sym tree");
         print(sp.warnings.join("\n"));
+         this.timerPrint("Compressed");
         
-        
-        var out = CompressWhite(new TokenStream(toks), this, this.keepWhite); // do not kill whitespace..
+         var out = CompressWhite(new TokenStream(toks), this, this.keepWhite); // do not kill whitespace..
         
         
         this.timerPrint("Compressed");
         
          if (out.length) {
-            File.write(minfile, str);
+            File.write(minfile, out);
         }
         
         return out;