We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 31c9004 commit 7ab525aCopy full SHA for 7ab525a
1 file changed
src/datetime-range.js
@@ -37,7 +37,7 @@ angular.module('g1b.datetime-range', []).
37
// Get number of weeks in month
38
scope.getNumWeeks = function () {
39
if ( !scope.calendar ) { return; }
40
- return (scope.calendar.clone().endOf('month').endOf('week').diff(scope.calendar.clone().startOf('month').startOf('week'), 'days') / 7) + 1;
+ return Math.floor(scope.calendar.clone().endOf('month').endOf('week').diff(scope.calendar.clone().startOf('month').startOf('week'), 'days') / 7) + 1;
41
}
42
43
// Set selected date
0 commit comments