title: FluentValidation ModelState.IsValid always true
body: <p>Ok my problem is the modelvalidator from fluentValidation is not working in my project, and ModelState.IsValid is always true no matter the state of the validation, im using asp.net mvc 4, .net 4.5, thx in advance.</p>
  
  <p>Global.asax</p>
  
  <pre><code>protected void Application_Start()
      {
          AreaRegistration.RegisterAllAreas();
  
          WebApiConfig.Register(GlobalConfiguration.Configuration);
          FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
          RouteConfig.RegisterRoutes(RouteTable.Routes);
          BundleConfig.RegisterBundles(BundleTable.Bundles);
          AuthConfig.RegisterAuth();
          FluentValidationModelValidatorProvider.Configure();
      }
  </code></pre>
  
  <p>LoginViewModel</p>
  
  <pre><code>using FluentValidation.Attributes;
  
  namespace ViewModel.Cuentas
  {
  
   [Validator(typeof(LoginViewModel))]
   public class LoginViewModel
   {
      public string UserName { get; set; }
      public string Password { get; set; }
   }
  }
  </code></pre>
  
  <p>LoginViewModelValidator</p>
  
  <pre><code>using FluentValidation;
  using FluentValidation.Results;
  namespace ViewModel.Cuentas.Validadores
  {
      public class LoginViewModelValidator : AbstractValidator&lt;LoginViewModel&gt;
      {
          public LoginViewModelValidator()
          {
          RuleFor(x =&gt; x.UserName).NotEmpty().WithMessage("El Campo Usuario es Necesario");
          RuleFor(x =&gt; x.Password).NotEmpty().WithMessage("El Campo Usuario es Necesario");
          }
     }
  }
  </code></pre>
  
  <p>and my account controller</p>
  
  <blockquote>
  <pre><code>   [HttpPost]
      [AllowAnonymous]
      [ValidateAntiForgeryToken]
      public ActionResult Login(LoginViewModel viewModel)
      {
          if (!ModelState.IsValid)
          {
              return View();
          }
          FormsAuthentication.SetAuthCookie(viewModel.UserName, false);
          if (!String.IsNullOrEmpty(returnUrl) &amp;&amp; returnUrl != "/")
          {
              return Redirect(returnUrl);
          }
          return RedirectToAction("Enviar", "Cartas");
      }
  </code></pre>
  </blockquote>