diff options
author | Scrutinizer Auto-Fixer <auto-fixer@scrutinizer-ci.com> | 2014-02-19 09:31:54 +0100 |
---|---|---|
committer | Scrutinizer <auto-fixer@scrutinizer-ci.com> | 2014-02-19 09:31:54 +0100 |
commit | adaee6a5a19a4b0050d189736bd4e6183fee9cf0 (patch) | |
tree | a553fc57c2ff8c99081f8e15fbee7dff2c00adbf /lib/public | |
parent | 1e321406ee2d973e937637ab090cbd83a6eb40cf (diff) | |
download | nextcloud-server-adaee6a5a19a4b0050d189736bd4e6183fee9cf0.tar.gz nextcloud-server-adaee6a5a19a4b0050d189736bd4e6183fee9cf0.zip |
Scrutinizer Auto-Fixes
This patch was automatically generated as part of the following inspection:
https://scrutinizer-ci.com/g/owncloud/core/inspections/cdfecc4e-a37e-4233-8025-f0d7252a8720
Enabled analysis tools:
- PHP Analyzer
- JSHint
- PHP Copy/Paste Detector
- PHP PDepend
Diffstat (limited to 'lib/public')
-rw-r--r-- | lib/public/appframework/controller.php | 4 | ||||
-rw-r--r-- | lib/public/backgroundjob.php | 4 | ||||
-rw-r--r-- | lib/public/backgroundjob/ijob.php | 1 | ||||
-rw-r--r-- | lib/public/backgroundjob/ijoblist.php | 7 | ||||
-rw-r--r-- | lib/public/contacts/imanager.php | 4 | ||||
-rw-r--r-- | lib/public/files.php | 1 | ||||
-rw-r--r-- | lib/public/iappconfig.php | 2 | ||||
-rw-r--r-- | lib/public/iconfig.php | 2 | ||||
-rw-r--r-- | lib/public/itags.php | 4 | ||||
-rw-r--r-- | lib/public/share.php | 13 |
10 files changed, 31 insertions, 11 deletions
diff --git a/lib/public/appframework/controller.php b/lib/public/appframework/controller.php index dc8da967871..7c2219bd046 100644 --- a/lib/public/appframework/controller.php +++ b/lib/public/appframework/controller.php @@ -68,7 +68,7 @@ abstract class Controller { * 1. URL parameters * 2. POST parameters * 3. GET parameters - * @param mixed $default If the key is not found, this value will be returned + * @param string $default If the key is not found, this value will be returned * @return mixed the content of the array */ public function params($key, $default=null){ @@ -131,7 +131,7 @@ abstract class Controller { * @param array $params the template parameters in key => value structure * @param string $renderAs user renders a full page, blank only your template * admin an entry in the admin settings - * @param array $headers set additional headers in name/value pairs + * @param string[] $headers set additional headers in name/value pairs * @return \OCP\AppFramework\Http\TemplateResponse containing the page */ public function render($templateName, array $params=array(), diff --git a/lib/public/backgroundjob.php b/lib/public/backgroundjob.php index bcd27c1d198..03b94403b47 100644 --- a/lib/public/backgroundjob.php +++ b/lib/public/backgroundjob.php @@ -59,7 +59,7 @@ class BackgroundJob { * sets the background jobs execution type * * @param string $type execution type - * @return boolean|null + * @return false|null * * This method sets the execution type of the background jobs. Possible types * are "none", "ajax", "webcron", "cron" @@ -115,7 +115,7 @@ class BackgroundJob { * @deprecated * Gets one queued task * @param int $id ID of the task - * @return \OC\BackgroundJob\Job|null array + * @return BackgroundJob\IJob array */ public static function findQueuedTask($id) { $jobList = \OC::$server->getJobList(); diff --git a/lib/public/backgroundjob/ijob.php b/lib/public/backgroundjob/ijob.php index 5231e9537a9..eaf11c4f684 100644 --- a/lib/public/backgroundjob/ijob.php +++ b/lib/public/backgroundjob/ijob.php @@ -14,6 +14,7 @@ interface IJob { * * @param \OCP\BackgroundJob\IJobList $jobList The job list that manages the state of this job * @param \OC\Log $logger + * @return void */ public function execute($jobList, $logger = null); diff --git a/lib/public/backgroundjob/ijoblist.php b/lib/public/backgroundjob/ijoblist.php index 72f3fe863da..c9b546605b8 100644 --- a/lib/public/backgroundjob/ijoblist.php +++ b/lib/public/backgroundjob/ijoblist.php @@ -14,14 +14,17 @@ interface IJobList { * * @param \OCP\BackgroundJob\IJob |string $job * @param mixed $argument The argument to be passed to $job->run() when the job is exectured + * @param string $job + * @return void */ public function add($job, $argument = null); /** * Remove a job from the list * - * @param \OCP\BackgroundJob\IJob|string $job + * @param IJob $job * @param mixed $argument + * @return void */ public function remove($job, $argument = null); @@ -58,6 +61,7 @@ interface IJobList { * set the job that was last ran to the current time * * @param \OCP\BackgroundJob\IJob $job + * @return void */ public function setLastJob($job); @@ -72,6 +76,7 @@ interface IJobList { * set the lastRun of $job to now * * @param \OCP\BackgroundJob\IJob $job + * @return void */ public function setLastRun($job); } diff --git a/lib/public/contacts/imanager.php b/lib/public/contacts/imanager.php index da9bca75525..5b9d64ecc41 100644 --- a/lib/public/contacts/imanager.php +++ b/lib/public/contacts/imanager.php @@ -96,7 +96,7 @@ namespace OCP\Contacts { * This function can be used to delete the contact identified by the given id * * @param object $id the unique identifier to a contact - * @param $address_book_key + * @param $address_book_key * @return bool successful or not */ function delete($id, $address_book_key); @@ -106,7 +106,7 @@ namespace OCP\Contacts { * Otherwise the contact will be updated by replacing the entire data set. * * @param array $properties this array if key-value-pairs defines a contact - * @param $address_book_key string to identify the address book in which the contact shall be created or updated + * @param $address_book_key string to identify the address book in which the contact shall be created or updated * @return array representing the contact just created or updated */ function createOrUpdate($properties, $address_book_key); diff --git a/lib/public/files.php b/lib/public/files.php index 75c52b88fc7..e2d9c81d442 100644 --- a/lib/public/files.php +++ b/lib/public/files.php @@ -37,7 +37,6 @@ namespace OCP; class Files { /** * Recusive deletion of folders - * @param string $path to the folder * @return bool */ static function rmdirr( $dir ) { diff --git a/lib/public/iappconfig.php b/lib/public/iappconfig.php index 3b6484c09d5..1f31898bf2c 100644 --- a/lib/public/iappconfig.php +++ b/lib/public/iappconfig.php @@ -57,6 +57,7 @@ interface IAppConfig { * * @param app * @param key + * @param string $key * @return array */ public function getValues($app, $key); @@ -68,6 +69,7 @@ interface IAppConfig { * @param string $value value * * Sets a value. If the key did not exist before it will be created. + * @return void */ public function setValue($app, $key, $value); diff --git a/lib/public/iconfig.php b/lib/public/iconfig.php index 8944e660780..0ebbd9f5a71 100644 --- a/lib/public/iconfig.php +++ b/lib/public/iconfig.php @@ -47,7 +47,7 @@ interface IConfig { * Looks up a system wide defined value * * @param string $key the key of the value, under which it was saved - * @param mixed $default the default value to be returned if the value isn't set + * @param string $default the default value to be returned if the value isn't set * @return string the saved value */ public function getSystemValue($key, $default = ''); diff --git a/lib/public/itags.php b/lib/public/itags.php index 7965d4152f9..f8ebaa668f1 100644 --- a/lib/public/itags.php +++ b/lib/public/itags.php @@ -147,7 +147,7 @@ interface ITags { * Creates a tag/object relation. * * @param int $objid The id of the object - * @param int|string $tag The id or name of the tag + * @param string $tag The id or name of the tag * @return boolean Returns false on database error. */ public function tagAs($objid, $tag); @@ -156,7 +156,7 @@ interface ITags { * Delete single tag/object relation from the db * * @param int $objid The id of the object - * @param int|string $tag The id or name of the tag + * @param string $tag The id or name of the tag * @return boolean */ public function unTag($objid, $tag); diff --git a/lib/public/share.php b/lib/public/share.php index f6c44a8322b..ebc555dba5f 100644 --- a/lib/public/share.php +++ b/lib/public/share.php @@ -78,6 +78,9 @@ class Share { * @param string Backend class * @param string (optional) Depends on item type * @param array (optional) List of supported file extensions if this item type depends on files + * @param string $itemType + * @param string $class + * @param string $collectionOf * @return boolean true if backend is registered or false if error */ public static function registerBackend($itemType, $class, $collectionOf = null, $supportedFileExtensions = null) { @@ -404,6 +407,7 @@ class Share { * @param mixed Parameters * @param int Number of items to return (optional) Returns all by default * @param bool include collections + * @param string $itemType * @return Return depends on format */ public static function getItemsShared($itemType, $format = self::FORMAT_NONE, $parameters = null, @@ -662,6 +666,8 @@ class Share { * Unshare an item from all users, groups, and remove all links * @param string Item type * @param string Item source + * @param string $itemType + * @param string $itemSource * @return boolean true on success or false on failure */ public static function unshareAll($itemType, $itemSource) { @@ -694,6 +700,8 @@ class Share { * Unshare an item shared with the current user * @param string Item type * @param string Item target + * @param string $itemType + * @param string $itemTarget * @return boolean true on success or false on failure * * Unsharing from self is not allowed for items inside collections @@ -1630,6 +1638,7 @@ class Share { * @param string User that is the owner of shared item * @param string The suggested target originating from a reshare (optional) * @param int The id of the parent group share (optional) + * @param integer $shareType * @return string Item target */ private static function generateTarget($itemType, $itemSource, $shareType, $shareWith, $uidOwner, @@ -1937,6 +1946,8 @@ interface Share_Backend { * Get the source of the item to be stored in the database * @param string Item source * @param string Owner of the item + * @param string $itemSource + * @param string $uidOwner * @return boolean Source * * Return an array if the item is file dependent, the array needs two keys: 'item' and 'file' @@ -1993,6 +2004,8 @@ interface Share_Backend_File_Dependent extends Share_Backend { * Get the file path of the item * @param string Item source * @param string User that is the owner of shared item + * @param string $itemSource + * @param string $uidOwner * @return boolean */ public function getFilePath($itemSource, $uidOwner); |