/**
* Attempt to find a user in the system otherwise register them as a new
* user. For use with external auth systems since password is auto-generated.
+ *
* @throws UserRegistrationException
*/
public function findOrRegister(string $name, string $email, string $externalId): User
}
// Create the user
- $newUser = $this->userRepo->registerNew($userData, $emailConfirmed);
+ $newUser = $this->userRepo->createWithoutActivity($userData, $emailConfirmed);
+ $newUser->attachDefaultRole();
// Assign social account if given
if ($socialAccount) {