DocSpace-buildtools/common/ASC.Common/Web/HttpContext.cs

17 lines
435 B
C#
Raw Normal View History

using ASC.Common.DependencyInjection;
2019-06-06 08:44:38 +00:00
using Microsoft.AspNetCore.Http;
2019-05-15 14:56:09 +00:00
namespace ASC.Common
{
public static class HttpContext
2019-06-06 08:44:38 +00:00
{
public static Microsoft.AspNetCore.Http.HttpContext Current
{
get
{
var currentContext = CommonServiceProvider.GetService<IHttpContextAccessor>();
return currentContext?.HttpContext;
}
2019-05-15 14:56:09 +00:00
}
}
}