} else if (user.getUserAccountStatus() == null) {
// Throw NPE again
throw new NullPointerException("user.userAccountStatus is null"); //NOI18N
+ } else if (!this.userBean.ifUserExists(user)) {
+ // Name already found
+ throw new UserNotFoundException(user);
} else if (user.getUserAccountStatus() == UserAccountStatus.LOCKED) {
// Account is locked
throw new UserStatusLockedException(user);
} else if (user.getUserAccountStatus() == UserAccountStatus.UNCONFIRMED) {
- // Account is locked
+ // Account is unconfirmed
throw new UserStatusUnconfirmedException(user);
- } else if (!this.userBean.ifUserExists(user)) {
- // Name already found
- throw new UserNotFoundException(user);
} else if (null == userLockReason) {
// Throw NPE again
throw new NullPointerException("userLockReason is null"); //NOI18N
} else if (user.getUserAccountStatus() == null) {
// Throw NPE again
throw new NullPointerException("user.userAccountStatus is null"); //NOI18N
+ } else if (!this.userBean.ifUserExists(user)) {
+ // Name already found
+ throw new UserNotFoundException(user);
} else if (user.getUserAccountStatus() == UserAccountStatus.CONFIRMED) {
- // Account is locked
+ // Account is confirmed
throw new UserStatusConfirmedException(user);
} else if (user.getUserAccountStatus() == UserAccountStatus.UNCONFIRMED) {
- // Account is locked
+ // Account is unconfirmed
throw new UserStatusUnconfirmedException(user);
- } else if (!this.userBean.ifUserExists(user)) {
- // Name already found
- throw new UserNotFoundException(user);
}
// Remove contact instance as this is not updated