public IActionResult Revalidate(RevalidateModel model)
        {
            var user = UserHelper.GetUser(model.id);

            // Uses the hasher to compare the user's password and the
            // password that they just entered.
            if (Hasher.ValidatePassword(model.Password, user.Password))
            {
                // Let them update their details if they got it right.
                UpdateUser ret = new UpdateUser()
                {
                    UserID    = user.UserID,
                    Username  = user.Username,
                    Firstname = user.First_Name,
                    Lastname  = user.Last_Name
                };
                return(View("Update", ret));
            }
            // If the user got the password wrong
            // they probably aren't the user
            // so log them out.
            UserHelper.LogOut(HttpContext.Session);
            OrganisationHelper.LogOut(HttpContext.Session);
            return(RedirectToAction("Index", "Home"));
        }
        public IActionResult Index(Users user)
        {
            var model = new RevalidateModel()
            {
                id            = user.UserID,
                AspAction     = "Revalidate",
                AspController = "Account"
            };

            return(View("Revalidate", model));
        }