mirror of https://github.com/zulip/zulip.git
timerender: Fix comparison of Date objects.
This === comparison between two Date objects added by commit
9896782fd1
(#17220) always returned
false, so the body of timerender was running every minute instead of
every day.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
parent
23b589cce3
commit
63eae63a07
|
@ -3,6 +3,7 @@ import {
|
|||
differenceInCalendarDays,
|
||||
format,
|
||||
formatISO,
|
||||
isEqual,
|
||||
isValid,
|
||||
parseISO,
|
||||
startOfToday,
|
||||
|
@ -181,7 +182,7 @@ export function render_markdown_timestamp(time, text) {
|
|||
// testing purposes.
|
||||
export function update_timestamps() {
|
||||
const today = startOfToday();
|
||||
if (today !== last_update) {
|
||||
if (!isEqual(today, last_update)) {
|
||||
const to_process = update_list;
|
||||
update_list = [];
|
||||
|
||||
|
|
Loading…
Reference in New Issue