Skip to content

Commit

Permalink
Fix always-true comparisons in isToday()
Browse files Browse the repository at this point in the history
  • Loading branch information
AbeJellinek authored and adomasven committed Apr 5, 2024
1 parent 9c89b23 commit fbc4d6a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions date.js
Original file line number Diff line number Diff line change
Expand Up @@ -872,8 +872,8 @@ var Utilities_Date = new function(){
function isToday(date) {
var d = new Date();
return d.getDate() == date.getDate()
&& d.getMonth() == d.getMonth()
&& d.getFullYear() == d.getFullYear();
&& d.getMonth() == date.getMonth()
&& d.getFullYear() == date.getFullYear();
}


Expand Down

0 comments on commit fbc4d6a

Please sign in to comment.