Merge pull request #222 from sfate/patch-1

Match weekend days properly
This commit is contained in:
Valeriy 2015-01-06 16:15:10 +05:00
commit c4e6fdaeb7

View File

@ -1358,7 +1358,7 @@
classes.push('xdsoft_today');
}
if (start.getDay() === 0 || start.getDay() === 6 || options.weekends.indexOf(start.dateFormat(options.formatDate)) === -1) {
if (start.getDay() === 0 || start.getDay() === 6 || ~options.weekends.indexOf(start.dateFormat(options.formatDate))) {
classes.push('xdsoft_weekend');
}