Handle render exceptions and set content-type for JsonModel