private IEvent CompleteStory(CompleteStoryCommand command) { //if (Version == -1) //{ // throw new StoryNotFoundException(); //} if (IsCompleted) { throw new StoryCompletedException(); } return(Apply(new StoryCompletedEvent(Id))); }
public async Task CompleteStory([FromBody] CompleteStoryCommand completeStoryCommand) { await _mediator.Send(completeStoryCommand); }