PacktPublishing / Software-Architecture-with-C-9-and-.NET-5

Code Repository created for Hands-On Software Architecture with C# 9 and .NET 5, Published by Packt
MIT License
39 stars 36 forks source link

Updates for Chapter 12 #15

Closed serpent5 closed 3 years ago

serpent5 commented 3 years ago

The registration of the IEventHandler<T> implementation needs to be registered as IEventHandler<T> instead of the concrete type. Otherwise, the IEnumerable<IEventHandler<T>> passed into EventTrigger's constructor is empty.

I'll submit another PR that makes this change across the other chapters once this one's been merged.

frankabbruzzese commented 3 years ago

I tested this way in chapter 15 example, and it worked! Anyway, what you say is correct!