public ActionResult Settings(SettingsModel model) { // Redirect if the user isn't logged in if (!IdentityModel.CurrentUserLoggedIn) { return RedirectToAction("Login", "Admin"); } model.SaveSettings(); return View(model); }
public ActionResult Settings() { // Redirect if the user isn't logged in if (!IdentityModel.CurrentUserLoggedIn || !IdentityModel.CurrentUserOwner) { return RedirectToAction("Index", "Admin"); } var model = new SettingsModel(); model.LoadSettings(); return View(model); }