Skip to content

Commit

Permalink
Do not use $_GET
Browse files Browse the repository at this point in the history
The appframework is more than capable of handling this properly.

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
  • Loading branch information
rullzer committed Jan 5, 2020
1 parent d7fdab0 commit 019e0f5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions apps/files_sharing/lib/Controller/ShareesAPIController.php
Original file line number Diff line number Diff line change
Expand Up @@ -198,8 +198,8 @@ public function search(string $search = '', string $itemType = null, int $page =
$shareTypes[] = Share::SHARE_TYPE_CIRCLE;
}

if (isset($_GET['shareType']) && is_array($_GET['shareType'])) {
$shareTypes = array_intersect($shareTypes, $_GET['shareType']);
if ($shareType !== null && is_array($shareType)) {
$shareTypes = array_intersect($shareTypes, $shareType);
sort($shareTypes);
} else if (is_numeric($shareType)) {
$shareTypes = array_intersect($shareTypes, [(int) $shareType]);
Expand Down

0 comments on commit 019e0f5

Please sign in to comment.