now setting the response headers before the body