mirror of
https://github.com/tomru/pfadi-bussle.git
synced 2026-03-03 06:27:11 +01:00
address breaking changes
This commit is contained in:
committed by
Thomas Ruoff
parent
8222e04880
commit
ef7f80fd92
@@ -122,15 +122,15 @@ export default function MyCalendar({
|
||||
|
||||
// when startDate missing or both are already set
|
||||
if (!startDate || (!!startDate && !!endDate)) {
|
||||
onChange({ startDate: dateFormatBackend(date), endDate: null })
|
||||
onChange({ startDate: date, endDate: null })
|
||||
return
|
||||
}
|
||||
|
||||
// when startDate set, but end missing
|
||||
if (isAfter(date, startDate)) {
|
||||
onChange({ endDate: dateFormatBackend(date) })
|
||||
onChange({ endDate: date })
|
||||
} else {
|
||||
onChange({ startDate: dateFormatBackend(date), endDate: start })
|
||||
onChange({ startDate: date, endDate: date })
|
||||
}
|
||||
}}
|
||||
tileClassName={tileClassName}
|
||||
|
||||
Reference in New Issue
Block a user