public ActionResult Index(RegisterInputModel model)
        {
            if (ModelState.IsValid)
            {
                try
                {
                    var account = this.userAccountService.CreateAccount(model.Username, model.Password, model.Email);
                    
                    // add our custom stuff
                    account.FirstName = model.FirstName;
                    account.LastName = model.LastName;
                    this.userAccountService.Update(account);

                    if (userAccountService.Configuration.RequireAccountVerification)
                    {
                        return View("Success", model);
                    }
                    else
                    {
                        return View("Confirm", true);
                    }
                }
                catch (ValidationException ex)
                {
                    ModelState.AddModelError("", ex.Message);
                }
            }
            return View(model);
        }
 public ActionResult Index(RegisterInputModel model)
 {
     if (ModelState.IsValid)
     {
         try
         {
             var account = this.userAccountService.CreateAccount(model.Username, model.Password, model.Email);
             ViewData["RequireAccountVerification"] = this.userAccountService.Configuration.RequireAccountVerification;
             return View("Success", model);
         }
         catch (ValidationException ex)
         {
             ModelState.AddModelError("", ex.Message);
         }
     }
     return View(model);
 }
 public ActionResult Index(RegisterInputModel model)
 {
     if (ModelState.IsValid)
     {
         try
         {
             this.userAccountService.CreateAccount(model.Username, model.Password, model.Email);
             if (SecuritySettings.Instance.RequireAccountVerification)
             {
                 return View("Success", model);
             }
             else
             {
                 return View("Confirm", true);
             }
         }
         catch (ValidationException ex)
         {
             ModelState.AddModelError("", ex.Message);
         }
     }
     return View(model);
 }