gzip only works for json type (fixing prev. commit)