Fixes: U4-6093 ContentService.SaveAndPublishDo changes Culture
This commit is contained in:
@@ -78,7 +78,8 @@ namespace Umbraco.Core.Security
|
||||
/// <param name="http"></param>
|
||||
/// <param name="authenticateRequestIfNotFound">
|
||||
/// If set to true and a back office identity is not found and not authenticated, this will attempt to authenticate the
|
||||
/// request just as is done in the Umbraco module and then set the current identity if it is valid
|
||||
/// request just as is done in the Umbraco module and then set the current identity if it is valid.
|
||||
/// Just like in the UmbracoModule, if this is true then the user's culture will be assigned to the request.
|
||||
/// </param>
|
||||
/// <returns>
|
||||
/// Returns the current back office identity if an admin is authenticated otherwise null
|
||||
|
||||
@@ -50,7 +50,7 @@ namespace Umbraco.Web
|
||||
//if there is no current user, then use the admin
|
||||
if (user == null)
|
||||
{
|
||||
LogHelper.Warn(typeof(NotificationServiceExtensions), "There is no current Umbraco user logged in, the notifications will be sent from the administrator");
|
||||
LogHelper.Debug(typeof(NotificationServiceExtensions), "There is no current Umbraco user logged in, the notifications will be sent from the administrator");
|
||||
user = applicationContext.Services.UserService.GetUserById(0);
|
||||
if (user == null)
|
||||
{
|
||||
|
||||
@@ -286,7 +286,7 @@ namespace Umbraco.Web.Security
|
||||
/// <returns></returns>
|
||||
public int GetUserId()
|
||||
{
|
||||
var identity = _httpContext.GetCurrentIdentity(true);
|
||||
var identity = _httpContext.GetCurrentIdentity(false);
|
||||
if (identity == null)
|
||||
return -1;
|
||||
return Convert.ToInt32(identity.Id);
|
||||
@@ -298,7 +298,7 @@ namespace Umbraco.Web.Security
|
||||
/// <returns></returns>
|
||||
public string GetSessionId()
|
||||
{
|
||||
var identity = _httpContext.GetCurrentIdentity(true);
|
||||
var identity = _httpContext.GetCurrentIdentity(false);
|
||||
if (identity == null)
|
||||
return null;
|
||||
return identity.SessionId;
|
||||
|
||||
Reference in New Issue
Block a user