This is caused by the following code that appears everywhere in the code.
$scope.currentDate.setMonth(XXX)
For example:
if the currentDate = 31-Jan-2017 setting the month on februari
will result in 31-Feb-2017. That date does not exist and will result in 03-Mar-2017