Content Type now set also when some error occurs