Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBjoern Schiessle <bjoern@schiessle.org>2017-02-22 17:14:36 +0300
committerBjoern Schiessle <bjoern@schiessle.org>2017-06-01 13:34:12 +0300
commit59f4ffb9a38b778519d8fd5e766d2039cee7275f (patch)
treed6aa134c009611abc0360c26c1327c7d9b9a45e8 /apps/files_sharing
parentdecdb06e8923d52ea525d289c48f28283e41f85c (diff)
use (int) instead of intval for performance reasons
Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
Diffstat (limited to 'apps/files_sharing')
-rw-r--r--apps/files_sharing/lib/Controller/ShareesAPIController.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/files_sharing/lib/Controller/ShareesAPIController.php b/apps/files_sharing/lib/Controller/ShareesAPIController.php
index d6b517f3c43..2fb554f392c 100644
--- a/apps/files_sharing/lib/Controller/ShareesAPIController.php
+++ b/apps/files_sharing/lib/Controller/ShareesAPIController.php
@@ -429,13 +429,13 @@ class ShareesAPIController extends OCSController {
public function search($search = '', $itemType = null, $page = 1, $perPage = 200, $shareType = null, $lookup = true) {
// only search for string larger than a given threshold
- $threshold = intval($this->config->getSystemValue('sharing.minSearchStringLength', 0));
+ $threshold = (int)$this->config->getSystemValue('sharing.minSearchStringLength', 0);
if (strlen($search) < $threshold) {
return new DataResponse($this->result);
}
// never return more than the max. number of results configured in the config.php
- $maxResults = intval($this->config->getSystemValue('sharing.maxAutocompleteResults', 0));
+ $maxResults = (int)$this->config->getSystemValue('sharing.maxAutocompleteResults', 0);
if ($maxResults > 0) {
$perPage = min($perPage, $maxResults);
}