Merge branch 'dmp-refactoring' of https://code-repo.d4science.org/MaDgiK-CITE/argos into dmp-refactoring
This commit is contained in:
commit
e924270c88
|
@ -1011,6 +1011,9 @@ public class UserServiceImpl implements UserService {
|
|||
}
|
||||
this.addUserToTenant(tenantEntity, userInviteToTenantRequest);
|
||||
|
||||
action.setStatus(ActionConfirmationStatus.Accepted);
|
||||
this.entityManager.merge(action);
|
||||
|
||||
}
|
||||
|
||||
private void addUserToTenant(TenantEntity tenant, UserInviteToTenantRequestEntity userInviteToTenantRequest) throws InvalidApplicationException {
|
||||
|
@ -1023,8 +1026,8 @@ public class UserServiceImpl implements UserService {
|
|||
if (contactInfoEntity != null){
|
||||
userId = contactInfoEntity.getUserId();
|
||||
}
|
||||
|
||||
if (userId != null) {
|
||||
if (!userId.equals(this.userScope.getUserId())) throw new MyApplicationException("Cannot confirm invitation for different User");
|
||||
UserCredentialEntity userCredential = this.queryFactory.query(UserCredentialQuery.class).disableTracking().userIds(userId).first();
|
||||
if (userCredential == null) throw new MyApplicationException();
|
||||
|
||||
|
|
Loading…
Reference in New Issue