ensure correct DTEND value-type (timestamp) for later calculation in calendar import function

This commit is contained in:
Christian Binder 2006-11-03 13:17:00 +00:00
parent fa3a9da379
commit d3d8a90ee8

View File

@ -431,9 +431,11 @@
$vcardData['description'] = $attributes['value'];
break;
case 'DTEND':
if(date('H:i:s',$attributes['value']) == '00:00:00')
$attributes['value']--;
$vcardData['end'] = $attributes['value'];
$dtend_ts = is_numeric($attributes['value']) ? $attributes['value'] : $this->date2ts($attributes['value']);
if(date('H:i:s',$dtend_ts) == '00:00:00') {
$dtend_ts -= 60;
}
$vcardData['end'] = $dtend_ts;
break;
case 'DTSTART':
$vcardData['start'] = $attributes['value'];