private async Task FillSessionInfo(ViewModel model, CancellationToken cancellationToken) { var session = await this.GetSession(cancellationToken); if (session == null) { return; } model.SessionId = session.SessionId; model.AccountName = session.AccountName; model.AccountIdentity = session.AccountIdentity; }
protected async Task<ActionResult> View(ViewModel model, CancellationToken cancellationToken) { await this.FillSessionInfo(model, cancellationToken); return this.View(model); }