public ActionResult MailModifyAdvanced(string uniqueId, SpecialFolder specialFolder) { MailRepository mailRepository = Session["MailRepository"] as MailRepository; IMessageSummary getMessageInfo = mailRepository.GetMessageInfo(uniqueId, specialFolder); ViewBag.getMessageInfo = getMessageInfo; if (!getMessageInfo.Flags.Value.HasFlag(MessageFlags.Seen)) { MailAddFlags(uniqueId, MessageFlags.Seen); } return(View("~/Views/ControlPanel/MailAdvanced/MailModifyAdvanced.cshtml", mailRepository.GetMessage(uniqueId, specialFolder))); }