set headers during syncstatic DRY
handle case when Content-Encoding isn't set