mirror of
https://github.com/jellyfin/jellyfin.git
synced 2025-07-07 18:24:19 -04:00
put request message disposal back in
This commit is contained in:
parent
831dfaee87
commit
410b46f05d
@ -161,19 +161,19 @@ namespace MediaBrowser.Common.Implementations.HttpClientManager
|
|||||||
|
|
||||||
options.CancellationToken.ThrowIfCancellationRequested();
|
options.CancellationToken.ThrowIfCancellationRequested();
|
||||||
|
|
||||||
var message = GetHttpRequestMessage(options);
|
using (var message = GetHttpRequestMessage(options))
|
||||||
|
{
|
||||||
//if (options.EnableResponseCache && cachedInfo != null)
|
if (options.EnableResponseCache && cachedInfo != null)
|
||||||
//{
|
{
|
||||||
// if (!string.IsNullOrEmpty(cachedInfo.Etag))
|
if (!string.IsNullOrEmpty(cachedInfo.Etag))
|
||||||
// {
|
{
|
||||||
// message.Headers.Add("If-None-Match", cachedInfo.Etag);
|
message.Headers.Add("If-None-Match", cachedInfo.Etag);
|
||||||
// }
|
}
|
||||||
// else if (cachedInfo.LastModified.HasValue)
|
else if (cachedInfo.LastModified.HasValue)
|
||||||
// {
|
{
|
||||||
// message.Headers.IfModifiedSince = new DateTimeOffset(cachedInfo.LastModified.Value);
|
message.Headers.IfModifiedSince = new DateTimeOffset(cachedInfo.LastModified.Value);
|
||||||
// }
|
}
|
||||||
//}
|
}
|
||||||
|
|
||||||
if (options.ResourcePool != null)
|
if (options.ResourcePool != null)
|
||||||
{
|
{
|
||||||
@ -248,6 +248,8 @@ namespace MediaBrowser.Common.Implementations.HttpClientManager
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Performs a GET request and returns the resulting stream
|
/// Performs a GET request and returns the resulting stream
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user