public void EndGetOperationById(IAsyncResult result) { OperationDto operation = OperationsService.EndGetOperationById(result); OperationViewModel operationVM = Operations.SingleOrDefault(o => o.Operation.Id == operation.Id); if (operationVM != null) { operationVM.Operation = operation; } else { Operations.Add(new OperationViewModel(operation)); } InProgress = false; }