2016-02-16 15:07:42 +01:00
|
|
|
using System.Web;
|
|
|
|
|
|
|
|
|
|
namespace Umbraco.Web
|
|
|
|
|
{
|
|
|
|
|
internal class SingletonHttpContextAccessor : IHttpContextAccessor
|
|
|
|
|
{
|
|
|
|
|
public HttpContextBase Value
|
|
|
|
|
{
|
2016-11-16 09:57:24 +01:00
|
|
|
get
|
|
|
|
|
{
|
|
|
|
|
var httpContext = HttpContext.Current;
|
|
|
|
|
return httpContext == null ? null : new HttpContextWrapper(httpContext);
|
|
|
|
|
}
|
2016-02-16 15:07:42 +01:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|