moved setting useragent as far down the method chain within HttpRestClient as possible
Corrected some comments