title: Asp.net Identity 2.0 - Unique Email
body: <p>My application is MVC5, I tried to allow duplicate email address using the following:</p>
  
  <pre><code>public async Task&lt;ActionResult&gt; AddUser (UserRegisterViewModel userViewModel)
          {
         ......
              if (ModelState.IsValid)
                  {
                  var user = new ApplicationUser
                  {
                 ......
                  };
                  var adminresult = await UserManager.CreateAsync(user);
                  var result = await UserManager.AddToRolesAsync(user.Id, user.Profession);
                  UserManager.UserValidator = new UserValidator&lt;ApplicationUser&gt;(UserManager)
                  {
                      RequireUniqueEmail = false
                  };
                  if (adminresult.Succeeded)
                      {
                       ....
                      return RedirectToAction("VisitInfo", "Visit");
                      }
                  if (!adminresult.Succeeded)
                      {
                      var er = adminresult.Errors.FirstOrDefault();
                      ViewBag.Error = er;
                      return View(userViewModel);
                      }
  
                      return RedirectToAction("VisitInfo", "Visit");
                  }               
              return View();
              }
  </code></pre>
  
  <p>By adding  RequireUniqueEmail = false. It did not work, the page is redirected to login page!!
  My question is could I allow duplicate emails just for this action, and why I get redirected to login page?</p>