From a2cec25543711d33783cbf1e47e78eb8190cae0a Mon Sep 17 00:00:00 2001 From: Ludovic Marcotte Date: Thu, 28 Apr 2016 00:50:57 -0400 Subject: [PATCH] (fix) create cookie after password change using ppolicy --- UI/MainUI/SOGoRootPage.m | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/UI/MainUI/SOGoRootPage.m b/UI/MainUI/SOGoRootPage.m index 227f103d7..40ce07441 100644 --- a/UI/MainUI/SOGoRootPage.m +++ b/UI/MainUI/SOGoRootPage.m @@ -603,20 +603,20 @@ if (creds) { [SOGoSession deleteValueForSessionKey: [creds objectAtIndex: 1]]; - - if ([domain isNotNull]) - { - sd = [SOGoSystemDefaults sharedSystemDefaults]; - if ([sd enableDomainBasedUID] && - [username rangeOfString: @"@"].location == NSNotFound) - username = [NSString stringWithFormat: @"%@@%@", username, domain]; - } - - authCookie = [auth cookieWithUsername: username - andPassword: newPassword - inContext: context]; - [response addCookie: authCookie]; } + + if ([domain isNotNull]) + { + sd = [SOGoSystemDefaults sharedSystemDefaults]; + if ([sd enableDomainBasedUID] && + [username rangeOfString: @"@"].location == NSNotFound) + username = [NSString stringWithFormat: @"%@@%@", username, domain]; + } + + authCookie = [auth cookieWithUsername: username + andPassword: newPassword + inContext: context]; + [response addCookie: authCookie]; } else response = [self _responseWithLDAPPolicyError: error];