fix generateEventOutput for calendar hook
This commit is contained in:
parent
b6a8de8530
commit
6f20d51646
1 changed files with 2 additions and 5 deletions
|
@ -362,17 +362,14 @@ class OC_Calendar_App{
|
|||
* @return (array) $output - readable output
|
||||
*/
|
||||
public static function generateEventOutput($event, $start, $end){
|
||||
// Why is the following code necessary ? //
|
||||
/*if(isset($event['calendardata'])){
|
||||
if(isset($event['calendardata'])){
|
||||
$object = OC_VObject::parse($event['calendardata']);
|
||||
$vevent = $object->VEVENT;
|
||||
}else{
|
||||
$vevent = $event['vevent'];
|
||||
}*/
|
||||
}
|
||||
$return = array();
|
||||
$id = $event['id'];
|
||||
$object = $object = OC_VObject::parse($event['calendardata']);
|
||||
$vevent = $object->VEVENT;
|
||||
$allday = ($vevent->DTSTART->getDateType() == Sabre_VObject_Element_DateTime::DATE)?true:false;
|
||||
$last_modified = @$vevent->__get('LAST-MODIFIED');
|
||||
$lastmodified = ($last_modified)?$last_modified->getDateTime()->format('U'):0;
|
||||
|
|
Loading…
Reference in a new issue