diff options
author | Bjoern Schiessle <bjoern@schiessle.org> | 2017-02-22 15:14:36 +0100 |
---|---|---|
committer | Bjoern Schiessle <bjoern@schiessle.org> | 2017-02-22 15:14:36 +0100 |
commit | fe46c6f7439de71b33de21f937627a29f27a4844 (patch) | |
tree | f709192461892621eb549db9505f8002e519dcde | |
parent | 02ea84f50f79ff6df8bada46d7c1fe0287cbd636 (diff) | |
download | nextcloud-server-fe46c6f7439de71b33de21f937627a29f27a4844.tar.gz nextcloud-server-fe46c6f7439de71b33de21f937627a29f27a4844.zip |
use (int) instead of intval for performance reasons
Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
-rw-r--r-- | apps/files_sharing/lib/Controller/ShareesAPIController.php | 4 |
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 838dd1adf9b..e4b5b0ce19c 100644 --- a/apps/files_sharing/lib/Controller/ShareesAPIController.php +++ b/apps/files_sharing/lib/Controller/ShareesAPIController.php @@ -415,13 +415,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); } |