Merge branch 'master' into feature/files

This commit is contained in:
pavelbannov 2020-09-10 13:40:54 +03:00
commit 9282ffbbf1

View File

@ -34,7 +34,6 @@ using System.Threading.Tasks;
using System.Web;
using ASC.Common;
using ASC.Common.Web;
using ASC.Core;
using ASC.Security.Cryptography;
@ -134,8 +133,16 @@ namespace ASC.Data.Storage.DiscStorage
if (string.IsNullOrEmpty(toCopy)) continue;
context.Response.Headers[toCopy] = h.Substring(toCopy.Length + 1);
}
//try
//{
// context.Response.ContentType = MimeMapping.GetMimeMapping(path);
//}
//catch (Exception e)
//{
// var a = 0;
//}
context.Response.ContentType = MimeMapping.GetMimeMapping(path);
if (encoding != null)
context.Response.Headers["Content-Encoding"] = encoding;