refactor: remove redundant isRecurring property, use recurrenceRule instead
isRecurring was redundant since recurrenceRule as truthy/falsy check suffices. Removed from shared CalendarEvent type, Mongoose virtual, and all usages.
This commit is contained in:
@@ -48,7 +48,7 @@ export function expandRecurringEvents(
|
||||
// to find events that start before rangeStart but extend into the range
|
||||
const adjustedRangeStart = new Date(rangeStart.getTime() - duration);
|
||||
|
||||
if (!event.isRecurring || !event.recurrenceRule) {
|
||||
if (!event.recurrenceRule) {
|
||||
// Non-recurring event: add if it overlaps with the range
|
||||
if (endTime >= rangeStart && startTime <= rangeEnd) {
|
||||
expanded.push({
|
||||
|
||||
Reference in New Issue
Block a user