this cleans up the callcurl bits a bit