I am having an issue with the following javascript expression:
}else if(prnPosition == "Yes" && urgentCare && currentDate.getTime() < startDatePlus90Days.getTime()){alert("We are in the 90 day branch");}else if(prnPosition == "Yes" && currentDate.getTime() < startDatePlus180Days.getTime()){alert("We are in the 180 day branch");}else if(...
When the prnPosition is true and urgentCare is false and currentDateTime is less than the startDatePlus90Days it still goes into the 90 day branch. I would expect the code to bypass the 90 day branch and enter the 180 day branch.
It seems like something simple, but I'm not seeing why the code flows into the 90 day branch if the urgentCare variable value is false. Do I need to explicitly say: