Skip to content

Commit

Permalink
fix: check for error handling for format related issue
Browse files Browse the repository at this point in the history
  • Loading branch information
harshith-venkatesh-freshworks committed Nov 12, 2024
1 parent 99b4576 commit 1a2b66f
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1033,9 +1033,10 @@ export class Datepicker {
year < this.minYear ||
year > this.maxYear ||
!isValid(parsedDate) ||
!isMatch(parsedDate, this.displayFormat, {
locale: this.langModule,
}) ||
(this.langModule?.code !== 'is' &&
!isMatch(parsedDate, this.displayFormat, {
locale: this.langModule,
})) ||
!this.isDateWithinMinMaxDate(parsedDate.valueOf(), false)
) {
console.info(
Expand Down

0 comments on commit 1a2b66f

Please sign in to comment.