fix(view/calendar): guard condition breaking recursion

This commit is contained in:
Elian Doran 2025-02-23 18:39:34 +02:00
parent 2578d480a8
commit 249c42e781
No known key found for this signature in database

View File

@ -280,9 +280,6 @@ export default class CalendarView extends ViewMode {
for (const note of notes) {
const startDate = note.getLabelValue("startDate");
if (!startDate) {
continue;
}
if (note.hasChildren()) {
const childrenEventData = await this.#buildEvents(note.getChildNoteIds());
@ -291,6 +288,9 @@ export default class CalendarView extends ViewMode {
}
}
if (!startDate) {
continue;
}
const endDate = note.getAttributeValue("label", "endDate");
events.push(await CalendarView.#buildEvent(note, startDate, endDate));