- // Debug message
- //* NOISY-DEBUG: */ System.out.println(MessageFormat.format("{0}.createUserInstance: contact={1}", this.getClass().getSimpleName(), contact));
+ // Generate random password
+ String randomPassword = UserUtils.createRandomPassword(AddressbookUserWebSessionController.MINIMUM_PASSWORD_LENGTH);
+
+ // Set random password
+ this.setUserPassword(randomPassword);
+ this.setUserPasswordRepeat(randomPassword);
+ }
+
+ // Set user name and mode
+ user.setUserName(this.getUserName());
+ user.setUserProfileMode(this.getUserProfileMode());
+
+ // Is multiple registration page
+ if (!this.registerController.isMultiplePageEnabled()) {
+ // Create contact instance
+ Contact contact = this.contactController.createContactInstance();