Merge pull request #90 from Cyclonit/master

Fix duplicate requests to the NexusApi draining the rate limit
This commit is contained in:
Timothy Baldridge 2019-10-14 14:50:26 -06:00 committed by GitHub
commit 5e7d3e962a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -181,7 +181,10 @@ namespace Wabbajack.NexusApi
var response = responseTask.Result;
UpdateRemaining(response);
using (var stream = _httpClient.GetStreamSync(url))
var contentTask = response.Content.ReadAsStreamAsync();
contentTask.Wait();
using (var stream = contentTask.Result)
{
return stream.FromJSON<T>();
}