public async Task Handle(CommentEditedEvent notification, CancellationToken cancellationToken) { var comment = await _readModelRepository.GetAsync <CommentDetail>(notification.AggregateId); comment.When(notification); await _readModelRepository.UpdateAsync(comment); }
private void When(CommentEditedEvent @event) { _text = @event.Text; }
public void When(CommentEditedEvent @event) { Text = @event.Text; LastModificationTime = @event.OccurrenceTime; }