EventType wrong when reading projections
Akii opened this issue · 2 comments
Akii commented
This is due to the fact that the summary field contains anything but the EventType ("$>") when reading streams that are based on projections. The events (and the data) itself are fetched normally.
A possible solution to this problem is to set the feeds embed mode to FULL and fix the EventStore\StreamFeed\Entry::getType()
like this:
return (isset($this->json['eventType'])) ? $this->json['eventType'] : $this->json['summary'];
Should this be an acceptable solution, I'd gladly provide a pull-request.
mrsimonbennett commented
+1
dbellettini commented
can you please post a code example or better a failing PHPUnit test case?