Compare sequence number from iTip replies
This commit is contained in:
parent
3db5611180
commit
634cb85fb5
2 changed files with 4 additions and 4 deletions
|
@ -258,8 +258,8 @@ class libcalendaring_itip
|
|||
|
||||
// check if the given itip object matches the last state
|
||||
if ($existing) {
|
||||
$latest = ($event['sequence'] && $existing['sequence'] == $event['sequence']) ||
|
||||
(!$event['sequence'] && $existing['changed'] && $existing['changed'] >= $event['changed']);
|
||||
$latest = (isset($event['sequence']) && $existing['sequence'] == $event['sequence']) ||
|
||||
(!isset($event['sequence']) && $existing['changed'] && $existing['changed'] >= $event['changed']);
|
||||
}
|
||||
|
||||
// determine action for REQUEST
|
||||
|
@ -320,7 +320,7 @@ class libcalendaring_itip
|
|||
)
|
||||
)));
|
||||
}
|
||||
$action = $attendee['status'] == $status ? '' : 'update';
|
||||
$action = $attendee['status'] == $status || !$latest ? '' : 'update';
|
||||
$listed = true;
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -919,7 +919,7 @@ class libvcalendar implements Iterator
|
|||
if ($event['description'])
|
||||
$ve->add('DESCRIPTION', strtr($event['description'], array("\r\n" => "\n", "\r" => "\n"))); // normalize line endings
|
||||
|
||||
if ($event['sequence'])
|
||||
if (isset($event['sequence']))
|
||||
$ve->add('SEQUENCE', $event['sequence']);
|
||||
|
||||
if ($event['recurrence'] && !$recurrence_id) {
|
||||
|
|
Loading…
Add table
Reference in a new issue