Skip to content

Commit

Permalink
Update BookingList.tsx
Browse files Browse the repository at this point in the history
  • Loading branch information
aelassas committed Oct 14, 2023
1 parent edfe416 commit d3edb84
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion backend/src/components/BookingList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ function BookingList({
}
}, [pageSize]) // eslint-disable-line react-hooks/exhaustive-deps

const getDate = (date: Date) => {
const getDate = (date: string) => {
const d = new Date(date)
return `${bookcarsHelper.formatDatePart(d.getDate())}-${bookcarsHelper.formatDatePart(d.getMonth() + 1)}-${d.getFullYear()}`
}
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/components/BookingList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ function BookingList({
}
}, [pageSize]) // eslint-disable-line react-hooks/exhaustive-deps

const getDate = (date: Date) => {
const getDate = (date: string) => {
const d = new Date(date)
return `${bookcarsHelper.formatDatePart(d.getDate())}-${bookcarsHelper.formatDatePart(d.getMonth() + 1)}-${d.getFullYear()}`
}
Expand Down

0 comments on commit d3edb84

Please sign in to comment.