mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-28 18:43:49 +00:00
Apply new CS rules on the webdav feature
This commit is contained in:
@@ -36,17 +36,17 @@ class PropfindRequestAnalyzer
|
||||
$propfinds = $request->getElementsByTagNameNS('DAV:', 'propfind');
|
||||
|
||||
if (0 === $propfinds->count()) {
|
||||
throw new ParseRequestException("any propfind element found");
|
||||
throw new ParseRequestException('any propfind element found');
|
||||
}
|
||||
|
||||
if (1 < $propfinds->count()) {
|
||||
throw new ParseRequestException("too much propfind element found");
|
||||
throw new ParseRequestException('too much propfind element found');
|
||||
}
|
||||
|
||||
$propfind = $propfinds->item(0);
|
||||
|
||||
if (0 === $propfind->childNodes->count()) {
|
||||
throw new ParseRequestException("no element under propfind");
|
||||
throw new ParseRequestException('no element under propfind');
|
||||
}
|
||||
|
||||
$unknows = [];
|
||||
@@ -79,7 +79,6 @@ class PropfindRequestAnalyzer
|
||||
default => '',
|
||||
};
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
$props = array_filter(array_values($props), fn (string $item) => '' !== $item);
|
||||
@@ -98,7 +97,7 @@ class PropfindRequestAnalyzer
|
||||
self::KNOWN_PROPS,
|
||||
array_fill(0, count(self::KNOWN_PROPS), $default)
|
||||
),
|
||||
'unknowns' => []
|
||||
'unknowns' => [],
|
||||
];
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user