We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c48e8f3 commit 3e0350dCopy full SHA for 3e0350d
static-site/src/components/ListResources/useDataFetch.ts
@@ -163,7 +163,7 @@ function updateCadence(dateObjects) {
163
return {summary: "rarely", description: `This dataset has been updated ${intervals.length+1} times in the past 2 years.`};
164
}
165
166
- const lastUpdateDaysAgo = Math.round(((new Date()) - dateObjects.at(-1))/msInADay);
+ const lastUpdateDaysAgo = Math.round(((new Date()).getTime() - dateObjects.at(-1))/msInADay);
167
const median = intervals[Math.floor(intervals.length/2)];
168
const mad = intervals.map((x) => Math.abs(x-median)).sort((a, b) => a-b)[Math.floor(intervals.length/2)]
169
0 commit comments