refactor(SideBar): init in componentWillMount

This commit is contained in:
EnixCoda 2018-08-05 16:28:44 +08:00
parent 51f2db8bb7
commit 081be4ff4d

View file

@ -58,9 +58,8 @@ export default class Gitako extends React.PureComponent {
compressSingletonFolder: false,
}
constructor(props) {
super(props)
const { init } = props
componentWillMount() {
const { init } = this.props
init()
}