Skip to content

Commit 4d889c4

Browse files
DaanHooglanddhslove
authored andcommitted
Merge branch '4.19' into 4.20
1 parent a857e18 commit 4d889c4

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

engine/schema/src/main/java/com/cloud/projects/dao/ProjectAccountDaoImpl.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,7 @@ public void removeUserFromProjects(long userId) {
199199

200200
int removedCount = remove(sc);
201201
if (removedCount > 0) {
202-
s_logger.debug(String.format("Removed user [%s] from %s project(s).", userId, removedCount));
202+
logger.debug(String.format("Removed user [%s] from %s project(s).", userId, removedCount));
203203
}
204204
}
205205

server/src/main/java/com/cloud/user/AccountManagerImpl.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1528,7 +1528,7 @@ public void validateUserPasswordAndUpdateIfNeeded(String newPassword, UserVO use
15281528

15291529
User.Source userSource = user.getSource();
15301530
if (userSource == User.Source.SAML2 || userSource == User.Source.SAML2DISABLED || userSource == User.Source.LDAP) {
1531-
s_logger.warn(String.format("Unable to update the password for user [%d], as its source is [%s].", user.getId(), user.getSource().toString()));
1531+
logger.warn(String.format("Unable to update the password for user [%d], as its source is [%s].", user.getId(), user.getSource().toString()));
15321532
throw new InvalidParameterValueException("CloudStack does not support updating passwords for SAML or LDAP users. Please contact your cloud administrator for assistance.");
15331533
}
15341534

server/src/test/java/com/cloud/user/AccountManagerImplTest.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -881,7 +881,7 @@ public void validateUserPasswordAndUpdateIfNeededTestSaml2UserShouldNotBeAllowed
881881

882882
Mockito.when(userVoMock.getSource()).thenReturn(User.Source.SAML2);
883883

884-
accountManagerImpl.validateUserPasswordAndUpdateIfNeeded(newPassword, userVoMock, currentPassword);
884+
accountManagerImpl.validateUserPasswordAndUpdateIfNeeded(newPassword, userVoMock, currentPassword, false);
885885
}
886886

887887
@Test(expected = InvalidParameterValueException.class)
@@ -891,7 +891,7 @@ public void validateUserPasswordAndUpdateIfNeededTestSaml2DisabledUserShouldNotB
891891

892892
Mockito.when(userVoMock.getSource()).thenReturn(User.Source.SAML2DISABLED);
893893

894-
accountManagerImpl.validateUserPasswordAndUpdateIfNeeded(newPassword, userVoMock, currentPassword);
894+
accountManagerImpl.validateUserPasswordAndUpdateIfNeeded(newPassword, userVoMock, currentPassword, false);
895895
}
896896

897897
@Test(expected = InvalidParameterValueException.class)
@@ -901,7 +901,7 @@ public void validateUserPasswordAndUpdateIfNeededTestLdapUserShouldNotBeAllowedT
901901

902902
Mockito.when(userVoMock.getSource()).thenReturn(User.Source.LDAP);
903903

904-
accountManagerImpl.validateUserPasswordAndUpdateIfNeeded(newPassword, userVoMock, currentPassword);
904+
accountManagerImpl.validateUserPasswordAndUpdateIfNeeded(newPassword, userVoMock, currentPassword, false);
905905
}
906906

907907
private String configureUserMockAuthenticators(String newPassword) {

0 commit comments

Comments
 (0)