Skip to content

Commit

Permalink
fix(DateInput): rid of extra render
Browse files Browse the repository at this point in the history
  • Loading branch information
zouxuoz committed Nov 23, 2018
1 parent ad647ad commit 97a474b
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/atoms/dataEntry/DateInput/DateInput.js
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,11 @@ class DateInput extends React.Component<DateInputProps, DateInputState> {
}

open = () => {
this.setState({ isOpen: true });
const { isOpen } = this.state;

if (!isOpen) {
this.setState({ isOpen: true });
}
};

close = () => {
Expand Down

0 comments on commit 97a474b

Please sign in to comment.