Fix deprecated method http.createClient