private async Task DisplayEmailContent() { EmailModel model = null; List <EmailModel> allEmails = _emailManager.GetAllDownloadedEmails(); if (allEmails != null && SelectedEmail != null) { model = allEmails.FirstOrDefault(x => x.Id == SelectedEmail.Id); } if (model != null) { if (model.Body != null) { BodyHtml = model.Body.Html; } else { var body = await _emailManager.DownloadEmailBody(SelectedEmail.Id); BodyHtml = body; } } }