using Bootstrap.Admin.Models; using Bootstrap.DataAccess; using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Mvc; namespace Bootstrap.Admin.Controllers { /// /// /// public class HomeController : Controller { /// /// /// /// public IActionResult Index() { var url = DictHelper.RetrieveHomeUrl(); return url.Equals("~/Home/Index", System.StringComparison.OrdinalIgnoreCase) ? (IActionResult)View(new HeaderBarModel(User.Identity)) : Redirect(url); } /// /// /// /// /// [AllowAnonymous] public IActionResult Error(int id) { return id == 404 ? View("NotFound") : View(); } } }