update http client code