public async Task <ActionResult> EditGuest(Guid?guestId) { if (!guestId.HasValue) { return(null); } var guest = await _GuestManager.GetGuest(guestId.Value); return(PartialView("_Guest", guest as GuestViewModel)); }
public async Task <ActionResult> Index() { var guestId = Helpers.GetStorerIdFromCookie(Request.HttpContext); if (guestId == null) { throw new InvalidOperationException("Attempted to access stuff without being a valid guest"); } var guest = await _GuestManager.GetGuest(guestId.Value); return(View(guest)); }