Merge pull request #2760 from MediaBrowser/dev

Dev
pull/1154/head
Luke 7 years ago committed by GitHub
commit f1267ccb6a

@ -438,6 +438,15 @@ namespace Emby.Server.Implementations.HttpServer
options.CacheKey = cacheKey.GetMD5();
options.ContentFactory = () => Task.FromResult(GetFileStream(path, fileShare));
options.ResponseHeaders = options.ResponseHeaders ?? new Dictionary<string, string>(StringComparer.OrdinalIgnoreCase);
// Quotes are valid in linux. They'll possibly cause issues here
var filename = (Path.GetFileName(path) ?? string.Empty).Replace("\"", string.Empty);
if (!string.IsNullOrWhiteSpace(filename))
{
options.ResponseHeaders["Content-Disposition"] = "inline; filename=\"" + filename + "\"";
}
return GetStaticResult(requestContext, options);
}

@ -1,11 +1,11 @@
NZ-G,1
NZ-PG,5
NZ-M,6
NZ-R13,7
NZ-RP13,7
NZ-R15,8
NZ-RP16,9
NZ-R16,9
NZ-R18,10
NZ-RP13,7
NZ-RP16,9
NZ-R,10
NZ-M,10
NZ-MA,10

@ -512,10 +512,6 @@ namespace MediaBrowser.Api.Library
var headers = new Dictionary<string, string>();
// Quotes are valid in linux. They'll possibly cause issues here
var filename = Path.GetFileName(item.Path).Replace("\"", string.Empty);
headers["Content-Disposition"] = string.Format("attachment; filename=\"{0}\"", filename);
if (user != null)
{
LogDownload(item, user, auth);

@ -1,3 +1,3 @@
using System.Reflection;
[assembly: AssemblyVersion("3.2.25.7")]
[assembly: AssemblyVersion("3.2.25.8")]

Loading…
Cancel
Save