Merge pull request #140 from rschamp/feature/remove-session-listener-on-unmount

Remove the session listener on unmount
This commit is contained in:
Andrew Sliwinski 2015-10-23 08:48:56 -04:00
commit 9374d917dc

View file

@ -9,6 +9,9 @@ var Session = {
},
componentWillMount: function () {
window.addEventListener('session', this.updateSession);
},
componentWillUnmount: function () {
window.removeEventListener('session', this.updateSession);
}
};