diff --git a/.idea/workspace.xml b/.idea/workspace.xml index e3ee7ea..7379bc3 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -3,7 +3,7 @@ - + @@ -23,34 +23,12 @@ - - - - - - - - - - - - - - - - - - - - - - - - + + - - + + @@ -59,40 +37,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -104,6 +48,11 @@ @@ -152,10 +102,10 @@ - @@ -182,8 +132,6 @@ - - @@ -318,6 +266,8 @@ + + @@ -389,17 +339,21 @@ + + + + - - + - + @@ -436,11 +390,45 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - @@ -448,7 +436,6 @@ - @@ -456,7 +443,6 @@ - @@ -464,7 +450,6 @@ - @@ -472,7 +457,6 @@ - @@ -487,9 +471,6 @@ - - - @@ -536,13 +517,6 @@ - - - - - - - @@ -562,9 +536,6 @@ - - - @@ -587,12 +558,6 @@ - - - - - - @@ -607,7 +572,6 @@ - @@ -622,7 +586,6 @@ - @@ -644,7 +607,6 @@ - @@ -659,7 +621,6 @@ - @@ -698,7 +659,6 @@ - @@ -721,7 +681,6 @@ - @@ -736,7 +695,6 @@ - @@ -744,15 +702,12 @@ - - - - + @@ -762,38 +717,22 @@ - + - - - - - - - - - - - - - - - + - - + - @@ -801,8 +740,23 @@ + + + + + + + + + + + + + + - + + diff --git a/php/module.calendar.php b/php/module.calendar.php index 80da133..53e9b94 100644 --- a/php/module.calendar.php +++ b/php/module.calendar.php @@ -680,8 +680,16 @@ class CalendarModule extends Module if (!empty((string)$vEvent->{'X-ZARAFA-LABEL'})) { $properties["label"] = array_search((string)$vEvent->{'X-ZARAFA-LABEL'}, $this->labels); } - $properties["last_modification_time"] = (string)$vEvent->{'LAST-MODIFIED'}->getDateTime()->getTimestamp(); - $properties["creation_time"] = (string)$vEvent->CREATED->getDateTime()->getTimestamp(); + if (!empty((string)$vEvent->{'LAST-MODIFIED'})) { + $properties["last_modification_time"] = (string)$vEvent->{'LAST-MODIFIED'}->getDateTime()->getTimestamp(); + } else { + $properties["last_modification_time"] = time(); + } + if (!empty((string)$vEvent->CREATED)) { + $properties["creation_time"] = (string)$vEvent->CREATED->getDateTime()->getTimestamp(); + } else { + $properties["creation_time"] = time(); + } $properties["rrule"] = (string)$vEvent->RRULE; // Attendees