mirror of
https://github.com/alextselegidis/easyappointments.git
synced 2024-11-25 01:12:21 +03:00
JavaScript RangeError on appointment change causing disabled calendar dates (#1092).
This commit is contained in:
parent
25b44063b4
commit
cc6575d2d0
1 changed files with 1 additions and 1 deletions
|
@ -274,7 +274,7 @@ window.FrontendBookApi = window.FrontendBookApi || {};
|
||||||
|
|
||||||
// Select first enabled date.
|
// Select first enabled date.
|
||||||
var selectedDate = Date.parse(selectedDateString);
|
var selectedDate = Date.parse(selectedDateString);
|
||||||
var numberOfDays = new Date(selectedDate.getFullYear(), selectedDate.getMonth() + 1, 0).getDate();
|
var numberOfDays = moment(selectedDate).daysInMonth();
|
||||||
|
|
||||||
if (setDate && !GlobalVariables.manageMode) {
|
if (setDate && !GlobalVariables.manageMode) {
|
||||||
for (var i = 1; i <= numberOfDays; i++) {
|
for (var i = 1; i <= numberOfDays; i++) {
|
||||||
|
|
Loading…
Reference in a new issue