public IActionResult OnGet(int SelectedTalkId) { Talk = talkData.GetTalkById(SelectedTalkId); if (Talk == null) { return(RedirectToPage("./NotFound")); } return(Page()); }
public IActionResult OnGet(int SelectedTalkId) { talk = talkData.GetTalkById(SelectedTalkId); if (talk != null) { RedirectToPage("./Talks/NotFound"); } comments = commentData.GetAll(SelectedTalkId); Comment.TalkId = SelectedTalkId; Comment.userId = User.Claims.First(c => c.Type == "http://schemas.xmlsoap.org/ws/2005/05/identity/claims/nameidentifier").Value; userProfiles = accountData.GetAll(); return(Page()); }