Add missing EnsureSuccessStatusCode

This commit is contained in:
crobibero
2020-12-08 08:28:19 -07:00
parent 80ff564143
commit e621244405
3 changed files with 11 additions and 2 deletions

View File

@@ -407,6 +407,7 @@ namespace Emby.Server.Implementations.Updates
using var response = await _httpClientFactory.CreateClient(NamedClient.Default)
.GetAsync(new Uri(package.SourceUrl), cancellationToken).ConfigureAwait(false);
response.EnsureSuccessStatusCode();
await using var stream = await response.Content.ReadAsStreamAsync(cancellationToken).ConfigureAwait(false);
// CA5351: Do Not Use Broken Cryptographic Algorithms