The current broken version is unable to parse unusual custom formats such as YYYY/MM MMM/DD ddd.
The Moment date object created from Daily Notes 🧠/2023-09-08_Fri.md returns Fri Dec 08 2023 00:00:00 GMT-0800.
Note that it returns December instead of September.
The reason for this is that the current version is trying to create a Moment date object with DD ddd when "day" is passed into the getDateFromFile function.
As a result, the Moment library has the month as null and it automatically falls back to the current month, which is December now.
This causes all my previous notes to appear in the current month.
Turns out that daily/periodic notes require a unique file names to work properly and DD ddd generates duplicates. After I fixed that, the issue is now resolved. Closing this issue.
The current broken version is unable to parse unusual custom formats such as
YYYY/MM MMM/DD ddd
.The
Moment
date object created fromDaily Notes 🧠/2023-09-08_Fri.md
returnsFri Dec 08 2023 00:00:00 GMT-0800
. Note that it returns December instead of September.The reason for this is that the current version is trying to create a
Moment
date object withDD ddd
when"day"
is passed into thegetDateFromFile
function. As a result, theMoment
library has the month asnull
and it automatically falls back to the current month, which is December now.This causes all my previous notes to appear in the current month.