2019-05-17 11:58:09 +00:00
|
|
|
|
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
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|