Coerce includeTime to a boolean
This commit is contained in:
parent
d6c0505c49
commit
b5b7fab2a7
@ -28,7 +28,7 @@ export default class DateControl extends React.Component {
|
|||||||
const { field, includeTime, value } = this.props;
|
const { field, includeTime, value } = this.props;
|
||||||
const format = field.get('format', moment.defaultFormat);
|
const format = field.get('format', moment.defaultFormat);
|
||||||
return (<DateTime
|
return (<DateTime
|
||||||
timeFormat={includeTime}
|
timeFormat={!!includeTime}
|
||||||
value={moment(value, format)}
|
value={moment(value, format)}
|
||||||
onChange={this.handleChange}
|
onChange={this.handleChange}
|
||||||
/>);
|
/>);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user