Date-change notifications sent on page edit
cmacmackin opened this issue · 1 comments
cmacmackin commented
Two users have observed receiving date-change notifications when a page is edited, even though the due-date remains the same.
cmacmackin commented
This was because I was using the === operator to compare DateTime objects. When comparing objects (as opposed to primitive types) that operator tests for the same identity, which never evaluates to true when used in a real-world setting. However, my tests weren't catching this error because there I was passing in the same DateTime object for both the new and old due-dates.