mirror of
https://codeberg.org/icewind/SearchDAV.git
synced 2026-06-03 09:34:08 +02:00
Merge pull request #5 from icewind1991/scrutinizer-patch-1
Scrutinizer Auto-Fixes
This commit is contained in:
commit
b3fde1c79b
1 changed files with 3 additions and 3 deletions
|
|
@ -100,7 +100,7 @@ class SearchHandler {
|
|||
* @return Query
|
||||
*/
|
||||
private function getQueryForXML(BasicSearch $xml, array $allProps) {
|
||||
$orderBy = array_map(function (\SearchDAV\XML\Order $order) use ($allProps) {
|
||||
$orderBy = array_map(function(\SearchDAV\XML\Order $order) use ($allProps) {
|
||||
if (!isset($allProps[$order->property])) {
|
||||
throw new BadRequest('requested order by property is not a valid property for this scope');
|
||||
}
|
||||
|
|
@ -110,7 +110,7 @@ class SearchHandler {
|
|||
}
|
||||
return new Order($prop, $order->order);
|
||||
}, $xml->orderBy);
|
||||
$select = array_map(function ($propName) use ($allProps) {
|
||||
$select = array_map(function($propName) use ($allProps) {
|
||||
if (!isset($allProps[$propName])) {
|
||||
return;
|
||||
}
|
||||
|
|
@ -128,7 +128,7 @@ class SearchHandler {
|
|||
}
|
||||
|
||||
private function transformOperator(\SearchDAV\XML\Operator $operator, array $allProps) {
|
||||
$arguments = array_map(function ($argument) use ($allProps) {
|
||||
$arguments = array_map(function($argument) use ($allProps) {
|
||||
if (is_string($argument)) {
|
||||
if (!isset($allProps[$argument])) {
|
||||
throw new BadRequest('requested search property is not a valid property for this scope');
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue