Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Event's occurredOn attributes types should be immutable #20

Open
bystro opened this issue Jun 14, 2019 · 0 comments
Open

Event's occurredOn attributes types should be immutable #20

bystro opened this issue Jun 14, 2019 · 0 comments

Comments

@bystro
Copy link

bystro commented Jun 14, 2019

First of all I want to thank you boys for your job. I bought your e-book and find it useful.

Event's occurredOn attributes types should be immutable, but StoredEvent's occurredOn is mutable because of DateTime type.
https://github.com/dddinphp/ddd/blob/master/src/Domain/Event/StoredEvent.php#L34

Especially last-wishes app fires Event with DateTimeImmutable type - inconsistency that throws Exception.
https://github.com/bystro/last-wishes/blob/master/src/Lw/Domain/Model/User/UserRegistered.php#L19

Boys are you open for a PR? I can make some job.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant