FormidableLabs / freactal

Clean and robust state management for React and React-like libs.
MIT License
1.65k stars 46 forks source link

wrapped `this.unsubscribe` in exist check #41

Closed markacola closed 7 years ago

markacola commented 7 years ago

Fixes #40.

divmain commented 7 years ago

Can you squash into a single commit, and add a comment explaining why the check is necessary? Then I'll merge it in. Thanks!

mosesoak commented 7 years ago

syntax suggestion:

this.unsubscribe && this.unsubscribe(); // may be undefined due to an error in child render
divmain commented 7 years ago

Looks good. Thanks @markacola!