diff options
author | Bart Visscher <bartv@thisnet.nl> | 2014-02-28 13:53:41 +0100 |
---|---|---|
committer | Bart Visscher <bartv@thisnet.nl> | 2014-02-28 13:53:41 +0100 |
commit | 35a8dfb2fa7970098e6677f7b93b7d782d5df7f0 (patch) | |
tree | 8ede91547e256ece30635c7ab04d9bb08f63e671 | |
parent | 89e0763d3d511d2da878db43c89300c51850b0f3 (diff) | |
download | nextcloud-server-35a8dfb2fa7970098e6677f7b93b7d782d5df7f0.tar.gz nextcloud-server-35a8dfb2fa7970098e6677f7b93b7d782d5df7f0.zip |
More PHPDoc fixes, using scrutinizer patches as hints
-rw-r--r-- | lib/private/appconfig.php | 4 | ||||
-rw-r--r-- | lib/private/cache.php | 2 | ||||
-rw-r--r-- | lib/private/contactsmanager.php | 4 | ||||
-rw-r--r-- | lib/private/db.php | 5 | ||||
-rw-r--r-- | lib/private/image.php | 2 | ||||
-rw-r--r-- | lib/private/legacy/appconfig.php | 2 | ||||
-rwxr-xr-x | lib/private/request.php | 2 | ||||
-rw-r--r-- | lib/private/share/mailnotifications.php | 3 | ||||
-rw-r--r-- | lib/public/contacts/imanager.php | 4 | ||||
-rw-r--r-- | lib/public/iappconfig.php | 5 | ||||
-rw-r--r-- | tests/lib/appframework/routing/RoutingTest.php | 6 | ||||
-rw-r--r-- | tests/lib/dbschema.php | 3 |
12 files changed, 20 insertions, 22 deletions
diff --git a/lib/private/appconfig.php b/lib/private/appconfig.php index cdaaebb87e5..cfb84309c67 100644 --- a/lib/private/appconfig.php +++ b/lib/private/appconfig.php @@ -218,8 +218,8 @@ class AppConfig implements \OCP\IAppConfig { /** * get multiply values, either the app or key can be used as wildcard by setting it to false * - * @param boolean $app - * @param string $key + * @param string|false $app + * @param string|false $key * @return array */ public function getValues($app, $key) { diff --git a/lib/private/cache.php b/lib/private/cache.php index a311f10a00f..961270c334c 100644 --- a/lib/private/cache.php +++ b/lib/private/cache.php @@ -97,7 +97,7 @@ class Cache { /** * creates cache key based on the files given - * @param $files + * @param string[] $files * @return string */ static public function generateCacheKeyFromFiles($files) { diff --git a/lib/private/contactsmanager.php b/lib/private/contactsmanager.php index fc6745b4505..1cb3da7098f 100644 --- a/lib/private/contactsmanager.php +++ b/lib/private/contactsmanager.php @@ -47,7 +47,7 @@ namespace OC { * 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 string $address_book_key identifier of the address book in which the contact shall be deleted * @return bool successful or not */ public function delete($id, $address_book_key) { @@ -66,7 +66,7 @@ namespace OC { * 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 string $address_book_key identifier of the address book in which the contact shall be created or updated * @return array representing the contact just created or updated */ public function createOrUpdate($properties, $address_book_key) { diff --git a/lib/private/db.php b/lib/private/db.php index cfdac766bff..322a13642ae 100644 --- a/lib/private/db.php +++ b/lib/private/db.php @@ -313,9 +313,8 @@ class OC_DB { /** * @brief Insert a row if a matching row doesn't exists. - * @param string $table. The table to insert into in the form '*PREFIX*tableName' - * @param array $input. An array of fieldname/value pairs - * @param string $table + * @param string $table The table to insert into in the form '*PREFIX*tableName' + * @param array $input An array of fieldname/value pairs * @return boolean number of updated rows */ public static function insertIfNotExist($table, $input) { diff --git a/lib/private/image.php b/lib/private/image.php index 17caaa012f5..e0397ec8a00 100644 --- a/lib/private/image.php +++ b/lib/private/image.php @@ -34,7 +34,7 @@ class OC_Image { /** * @brief Get mime type for an image file. - * @param string|null $filepath The path to a local image file. + * @param string|null $filePath The path to a local image file. * @returns string The mime type if the it could be determined, otherwise an empty string. */ static public function getMimeTypeForFile($filePath) { diff --git a/lib/private/legacy/appconfig.php b/lib/private/legacy/appconfig.php index b6c3542a673..cb5cef7e350 100644 --- a/lib/private/legacy/appconfig.php +++ b/lib/private/legacy/appconfig.php @@ -116,8 +116,6 @@ class OC_Appconfig { /** * get multiply values, either the app or key can be used as wildcard by setting it to false * - * @param app - * @param key * @param string|false $app * @param string|false $key * @return array diff --git a/lib/private/request.php b/lib/private/request.php index afd3fda4f2d..59a9e395e85 100755 --- a/lib/private/request.php +++ b/lib/private/request.php @@ -26,7 +26,7 @@ class OC_Request { /** * @brief Checks whether a domain is considered as trusted. This is used to prevent Host Header Poisoning. - * @param string $host + * @param string $domain * @return bool */ public static function isTrustedDomain($domain) { diff --git a/lib/private/share/mailnotifications.php b/lib/private/share/mailnotifications.php index 360376294cc..afbf35aa397 100644 --- a/lib/private/share/mailnotifications.php +++ b/lib/private/share/mailnotifications.php @@ -30,7 +30,6 @@ class MailNotifications { /** * - * @param string $recipient user id * @param string $sender user id (if nothing is set we use the currently logged-in user) */ public function __construct($sender = null) { @@ -113,7 +112,7 @@ class MailNotifications { * @param string $filename the shared file * @param string $link the public link * @param int $expiration expiration date (timestamp) - * @return mixed $result true or error message + * @return string|boolean $result true or error message */ public function sendLinkShareMail($recipient, $filename, $link, $expiration) { $subject = (string)$this->l->t('%s shared »%s« with you', array($this->senderDisplayName, $filename)); diff --git a/lib/public/contacts/imanager.php b/lib/public/contacts/imanager.php index 5b9d64ecc41..005b71f298b 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 string $address_book_key identifier of the address book in which the contact shall be deleted * @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 string $address_book_key identifier of 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/iappconfig.php b/lib/public/iappconfig.php index 1f31898bf2c..2b014df2e42 100644 --- a/lib/public/iappconfig.php +++ b/lib/public/iappconfig.php @@ -55,9 +55,8 @@ interface IAppConfig { /** * get multiply values, either the app or key can be used as wildcard by setting it to false * - * @param app - * @param key - * @param string $key + * @param string|false $key + * @param string|false $app * @return array */ public function getValues($app, $key); diff --git a/tests/lib/appframework/routing/RoutingTest.php b/tests/lib/appframework/routing/RoutingTest.php index d0244cf2511..56e625fd168 100644 --- a/tests/lib/appframework/routing/RoutingTest.php +++ b/tests/lib/appframework/routing/RoutingTest.php @@ -166,9 +166,9 @@ class RouteConfigTest extends \PHPUnit_Framework_TestCase } /** - * @param $verb - * @param $controllerName - * @param $actionName + * @param string $verb + * @param string $controllerName + * @param string $actionName * @return \PHPUnit_Framework_MockObject_MockObject */ private function mockRoute($verb, $controllerName, $actionName) diff --git a/tests/lib/dbschema.php b/tests/lib/dbschema.php index 11e9fcdf4fa..cfa2d6fd9aa 100644 --- a/tests/lib/dbschema.php +++ b/tests/lib/dbschema.php @@ -71,6 +71,9 @@ class Test_DBSchema extends PHPUnit_Framework_TestCase { $this->assertTableNotExist($this->table2); } + /** + * @param string $table + */ public function tableExist($table) { switch (OC_Config::getValue( 'dbtype', 'sqlite' )) { |