Skip to content

Commit

Permalink
remove RoleNames from call to CreateUserAsync
Browse files Browse the repository at this point in the history
when registering a new user
  • Loading branch information
MichaelPetrinolis committed May 3, 2019
1 parent ae5ab7a commit 5f536f4
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -87,7 +87,7 @@ internal static async Task<IUser> RegisterUser(this Controller controller, Regis

if (controller.ModelState.IsValid)
{
var user = await userService.CreateUserAsync(new User { UserName = model.UserName, Email = model.Email, EmailConfirmed = !settings.UsersMustValidateEmail, RoleNames = new string[0] }, model.Password, (key, message) => controller.ModelState.AddModelError(key, message)) as User;
var user = await userService.CreateUserAsync(new User { UserName = model.UserName, Email = model.Email, EmailConfirmed = !settings.UsersMustValidateEmail }, model.Password, (key, message) => controller.ModelState.AddModelError(key, message)) as User;

if (user != null && controller.ModelState.IsValid)
{
Expand Down

0 comments on commit 5f536f4

Please sign in to comment.