mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-03-18 21:15:57 +00:00
Fix condition in weekly recurrence calculator
This commit is contained in:
1
NEWS
1
NEWS
@@ -9,6 +9,7 @@ Enhancements
|
||||
|
||||
Bug fixes
|
||||
- [web] fixed mail settings persistence when sorting by arrival date
|
||||
- [core] fixed condition in weekly recurrence calculator
|
||||
|
||||
3.2.1 (2016-11-02)
|
||||
------------------
|
||||
|
||||
@@ -160,8 +160,7 @@
|
||||
{
|
||||
r = [NGCalendarDateRange calendarDateRangeWithStartDate: currentStartDate
|
||||
endDate: currentEndDate];
|
||||
if ([_r containsDateRange: r] || [_r doesIntersectWithDateRange: r])
|
||||
[ranges addObject: r];
|
||||
[ranges addObject: r];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -125,16 +125,16 @@
|
||||
while ([currentStartDate compare: endDate] == NSOrderedAscending ||
|
||||
[currentStartDate compare: endDate] == NSOrderedSame)
|
||||
{
|
||||
currentEndDate = [currentStartDate addTimeInterval: [firstRange duration]];
|
||||
if ([startDate compare: currentStartDate] == NSOrderedAscending ||
|
||||
[startDate compare: currentStartDate] == NSOrderedSame)
|
||||
[startDate compare: currentStartDate] == NSOrderedSame ||
|
||||
[startDate compare: currentEndDate] == NSOrderedAscending)
|
||||
{
|
||||
NGCalendarDateRange *r;
|
||||
|
||||
currentEndDate = [currentStartDate addTimeInterval: [firstRange duration]];
|
||||
r = [NGCalendarDateRange calendarDateRangeWithStartDate: currentStartDate
|
||||
endDate: currentEndDate];
|
||||
if ([_r containsDateRange: r])
|
||||
[ranges addObject: r];
|
||||
[ranges addObject: r];
|
||||
}
|
||||
i++;
|
||||
currentStartDate = [firStart dateByAddingYears: 0
|
||||
|
||||
Reference in New Issue
Block a user