Upgrading ESLint and adding some more rules. Refactoring to meet these new rules

Этот коммит содержится в:
Christopher Speller
2015-11-19 18:10:08 -05:00
родитель c22e8129b0
Коммит 5c35c2631e
9 изменённых файлов: 42 добавлений и 21 удалений

Просмотреть файл

@@ -13,14 +13,14 @@ export default class CommandList extends React.Component {
this.getSuggestedCommands = this.getSuggestedCommands.bind(this);
this.state = {
suggestions: [ ],
suggestions: [],
cmd: ''
};
}
handleClick(i) {
this.props.addCommand(this.state.suggestions[i].suggestion);
this.setState({suggestions: [ ], cmd: ''});
this.setState({suggestions: [], cmd: ''});
}
addFirstCommand() {
@@ -36,7 +36,7 @@ export default class CommandList extends React.Component {
getSuggestedCommands(cmd) {
if (!cmd || cmd.charAt(0) !== '/') {
this.setState({suggestions: [ ], cmd: ''});
this.setState({suggestions: [], cmd: ''});
return;
}