Remove unused callbacks when setting state (#4015)

This commit is contained in:
Beto Dealmeida
2017-12-06 21:56:28 -08:00
committed by Maxime Beauchemin
parent cb7c5aa70c
commit 81df7087db

View File

@@ -58,23 +58,23 @@ export default class DateFilterControl extends React.Component {
}
}
onControlChange(target, opt) {
this.setState({ [target]: opt.value }, this.onChange);
this.setState({ [target]: opt.value });
}
onNumberChange(event) {
this.setState({ num: event.target.value }, this.onChange);
this.setState({ num: event.target.value });
}
onFreeChange(event) {
this.setState({ free: event.target.value }, this.onChange);
this.setState({ free: event.target.value });
}
setType(type) {
this.setState({ type }, this.onChange);
this.setState({ type });
}
setValue(val) {
this.setState({ type: 'free', free: val }, this.onChange);
this.setState({ type: 'free', free: val });
this.close();
}
setDatetime(dttm) {
this.setState({ dttm: dttm.format().substring(0, 19) }, this.onChange);
this.setState({ dttm: dttm.format().substring(0, 19) });
}
close() {
let val;