refactor(FileExplorer): init in componentWillMount

This commit is contained in:
EnixCoda 2018-08-05 18:24:53 +08:00
parent a0a7545492
commit a0efbd47db

View file

@ -35,9 +35,8 @@ export default class FileExplorer extends React.Component {
visibleNodes: null,
}
constructor(props) {
super(props)
const { init } = props
componentWillMount() {
const { init } = this.props
init()
}