asaskevich / EventBus

[Go] Lightweight eventbus with async compatibility for Go
MIT License
1.74k stars 220 forks source link

Allow call Publish with nil values #44

Closed erickskrauch closed 4 years ago

erickskrauch commented 4 years ago

In my application, it's common to have events with nil arguments. Example. Without this fix I always get reflect: Call using zero Value argument error.

This fix also should slightly increase performance by allocating all necessary memory to store arguments immediately.

asaskevich commented 4 years ago

Thank you!