mirror of
https://codeberg.org/icewind/SearchDAV.git
synced 2026-06-03 17:44:06 +02:00
No need to error out if the propery can't be found
Just don't search for it if it is not allowed. But we can still continue. Webdav will give a 404 if it can't be found later anyway. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
This commit is contained in:
parent
282bdeea56
commit
a292d9402a
1 changed files with 2 additions and 1 deletions
|
|
@ -112,7 +112,7 @@ class SearchHandler {
|
||||||
}, $xml->orderBy);
|
}, $xml->orderBy);
|
||||||
$select = array_map(function ($propName) use ($allProps) {
|
$select = array_map(function ($propName) use ($allProps) {
|
||||||
if (!isset($allProps[$propName])) {
|
if (!isset($allProps[$propName])) {
|
||||||
throw new BadRequest('requested property is not a valid property for this scope');
|
return;
|
||||||
}
|
}
|
||||||
$prop = $allProps[$propName];
|
$prop = $allProps[$propName];
|
||||||
if (!$prop->selectable) {
|
if (!$prop->selectable) {
|
||||||
|
|
@ -120,6 +120,7 @@ class SearchHandler {
|
||||||
}
|
}
|
||||||
return $prop;
|
return $prop;
|
||||||
}, $xml->select);
|
}, $xml->select);
|
||||||
|
$select = array_filter($select);
|
||||||
|
|
||||||
$where = $this->transformOperator($xml->where, $allProps);
|
$where = $this->transformOperator($xml->where, $allProps);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue