You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If I try to save a a aggregate root not having pending events with AggregateRepository::saveAggregateRoot, an exception is thrown by method AggregateRepository::isFirstEvent, since this method requires a Message object as first argument.
$firstEvent would be null if there is no pending event in $domainEvents.
If I try to save a a aggregate root not having pending events with
AggregateRepository::saveAggregateRoot
, an exception is thrown by methodAggregateRepository::isFirstEvent
, since this method requires aMessage
object as first argument.$firstEvent
would benull
if there is no pending event in$domainEvents
.I would prefer to throw a NoPendingEventsException, or not to do anything If there is no pending event.
Maybe an additional unit test is required for that use case.
The text was updated successfully, but these errors were encountered: