fixed KidsComponent event listener not falling off on unmount

This commit is contained in:
Anton Dyudin 2015-07-30 17:27:56 -07:00
parent 8039c0abba
commit c55d9ac147

View File

@ -23,6 +23,9 @@ module.exports = recl
(not _keys.isEmpty()) and _keys.every (k) =>
@state.cont[@state.path+"/"+k]?
componentWillUnmount: ->
TreeStore.removeChangeListener @_onChangeStore
componentDidMount: ->
TreeStore.addChangeListener @_onChangeStore
TreeActions.getPath @state.path,"kids" unless @gotPath()