Fixes #5457; Admin Culture Picker cookie not working on localhost

This commit is contained in:
Jasmin Savard
2015-06-30 13:09:19 -04:00
parent 583ff8951a
commit 28168c0550

View File

@@ -37,7 +37,7 @@ namespace Orchard.Localization.Selectors {
Expires = _clock.UtcNow.AddYears(DefaultExpireTimeYear),
};
cookie.Domain = httpContext.Request.Url.Host;
cookie.Domain = !httpContext.Request.IsLocal ? httpContext.Request.Url.Host : null;
if (!String.IsNullOrEmpty(_shellSettings.RequestUrlPrefix)) {
cookie.Path = GetCookiePath(httpContext);