style(caldav): improve getDenormalizedData method

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
pull/31790/head
Thomas Citharel 2023-06-23 09:09:38 +07:00 committed by Anna (Rebase PR Action)
parent 3886b00a33
commit 1e390e1982
1 changed files with 2 additions and 2 deletions

@ -2732,7 +2732,7 @@ class CalDavBackend extends AbstractBackend implements SyncSupport, Subscription
* @param string $calendarData
* @return array
*/
public function getDenormalizedData($calendarData) {
public function getDenormalizedData(string $calendarData): array {
$vObject = Reader::read($calendarData);
$vEvents = [];
$componentType = null;
@ -2746,7 +2746,7 @@ class CalDavBackend extends AbstractBackend implements SyncSupport, Subscription
if ($component->name !== 'VTIMEZONE') {
// Finding all VEVENTs, and track them
if ($component->name === 'VEVENT') {
array_push($vEvents, $component);
$vEvents[] = $component;
if ($component->DTSTART) {
$hasDTSTART = true;
}