Fixes gzip compression for javascript
Merge pull request #1014 from tonio/gzip

Fixes gzip compression for javascript