public async Task <AppUser> Add ( AppUserName userName, IHashedPassword password, PersonName name, EmailAddress email, DateTimeOffset timeAdded ) { var newUser = new AppUserRecord { UserName = userName.Value, Password = password.Value(), Name = name.Value, Email = email.Value, TimeAdded = timeAdded }; await factory.DB.Users.Create(newUser); return(factory.User(newUser)); }
public Task ChangePassword(IHashedPassword password) => factory.DB.Users.Update(record, u => u.Password = password.Value());