Skip to content

Commit

Permalink
style(caldav): improve getDenormalizedData method
Browse files Browse the repository at this point in the history
Signed-off-by: Thomas Citharel <[email protected]>
  • Loading branch information
tcitworld committed Jun 29, 2023
1 parent f5ff486 commit 936adda
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions apps/dav/lib/CalDAV/CalDavBackend.php
Original file line number Diff line number Diff line change
Expand Up @@ -2700,7 +2700,7 @@ protected function addChange($calendarId, $objectUri, $operation, $calendarType
* @param string $calendarData
* @return array
*/
public function getDenormalizedData($calendarData) {
public function getDenormalizedData(string $calendarData): array {
$vObject = Reader::read($calendarData);
$vEvents = [];
$componentType = null;
Expand All @@ -2714,7 +2714,7 @@ public function getDenormalizedData($calendarData) {
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;
}
Expand Down

0 comments on commit 936adda

Please sign in to comment.