fixed #14 and set content-type header