mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-10-13 07:47:12 +00:00
(fix) correctly handle "Day of the month" constraint
This commit is contained in:
1 parent
7d190e537e
commit
f3cf29ea1f
1 file changed
+11
-3
@@ -2028,9 +2028,17 @@ RANGE(2);
|
|||||||
occurence = [[self repeat3] intValue] + 1;
|
occurence = [[self repeat3] intValue] + 1;
|
||||||
if (occurence > 5) // the first/second/third/fourth/fifth ..
|
if (occurence > 5) // the first/second/third/fourth/fifth ..
|
||||||
occurence = -1; // the last ..
|
occurence = -1; // the last ..
|
||||||
[theRule setSingleValue: [NSString stringWithFormat: @"%d%@",
|
|
||||||
occurence, day]
|
// Day of the month (last, fourth, etc.)
|
||||||
forKey: @"byday"];
|
if ([[self repeat4] intValue] == 7)
|
||||||
|
{
|
||||||
|
[theRule setSingleValue: [NSString stringWithFormat: @"%d",occurence]
|
||||||
|
forKey: @"bymonthday"];
|
||||||
|
}
|
||||||
|
else
|
||||||
|
[theRule setSingleValue: [NSString stringWithFormat: @"%d%@",
|
||||||
|
occurence, day]
|
||||||
|
forKey: @"byday"];
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in new issue
Block a user