fix content-encoding
fixing problem of duplicate output