diff options
author | Scrutinizer Auto-Fixer <auto-fixer@scrutinizer-ci.com> | 2015-11-20 15:42:34 +0000 |
---|---|---|
committer | Scrutinizer Auto-Fixer <auto-fixer@scrutinizer-ci.com> | 2015-11-20 15:42:34 +0000 |
commit | 5573029485f7ecea806d3c58f6f0204c2e0651ad (patch) | |
tree | ed6c44809da98543a8f95f31b8eded62ae422395 /apps | |
parent | f3ff85832356e197ff03582d8ccab729dbc6d375 (diff) | |
download | nextcloud-server-5573029485f7ecea806d3c58f6f0204c2e0651ad.tar.gz nextcloud-server-5573029485f7ecea806d3c58f6f0204c2e0651ad.zip |
Scrutinizer Auto-Fixes
This commit consists of patches automatically generated for this project on https://scrutinizer-ci.com
Diffstat (limited to 'apps')
-rw-r--r-- | apps/dav/lib/caldav/caldavbackend.php | 7 | ||||
-rw-r--r-- | apps/dav/lib/carddav/carddavbackend.php | 6 | ||||
-rw-r--r-- | apps/dav/lib/connector/sabre/auth.php | 2 | ||||
-rw-r--r-- | apps/dav/lib/connector/sabre/fakelockerplugin.php | 4 | ||||
-rw-r--r-- | apps/dav/lib/connector/sabre/file.php | 10 | ||||
-rw-r--r-- | apps/dav/lib/connector/sabre/lockplugin.php | 1 | ||||
-rw-r--r-- | apps/dav/lib/connector/sabre/node.php | 6 | ||||
-rw-r--r-- | apps/dav/lib/connector/sabre/principal.php | 2 | ||||
-rw-r--r-- | apps/dav/tests/unit/connector/sabre/file.php | 5 | ||||
-rw-r--r-- | apps/dav/tests/unit/connector/sabre/filesplugin.php | 3 | ||||
-rw-r--r-- | apps/dav/tests/unit/connector/sabre/requesttest/auth.php | 4 |
11 files changed, 30 insertions, 20 deletions
diff --git a/apps/dav/lib/caldav/caldavbackend.php b/apps/dav/lib/caldav/caldavbackend.php index 08a2a70c56d..99338650793 100644 --- a/apps/dav/lib/caldav/caldavbackend.php +++ b/apps/dav/lib/caldav/caldavbackend.php @@ -217,7 +217,6 @@ class CalDavBackend extends AbstractBackend implements SyncSupport, Subscription * * Read the PropPatch documentation for more info and examples. * - * @param string $path * @param \Sabre\DAV\PropPatch $propPatch * @return void */ @@ -375,7 +374,7 @@ class CalDavBackend extends AbstractBackend implements SyncSupport, Subscription * If the backend supports this, it may allow for some speed-ups. * * @param mixed $calendarId - * @param array $uris + * @param string[] $uris * @return array */ function getMultipleCalendarObjects($calendarId, array $uris) { @@ -422,7 +421,7 @@ class CalDavBackend extends AbstractBackend implements SyncSupport, Subscription * @param mixed $calendarId * @param string $objectUri * @param string $calendarData - * @return string|null + * @return string */ function createCalendarObject($calendarId, $objectUri, $calendarData) { $extraData = $this->getDenormalizedData($calendarData); @@ -464,7 +463,7 @@ class CalDavBackend extends AbstractBackend implements SyncSupport, Subscription * @param mixed $calendarId * @param string $objectUri * @param string $calendarData - * @return string|null + * @return string */ function updateCalendarObject($calendarId, $objectUri, $calendarData) { $extraData = $this->getDenormalizedData($calendarData); diff --git a/apps/dav/lib/carddav/carddavbackend.php b/apps/dav/lib/carddav/carddavbackend.php index 348c166a531..daa31725fa1 100644 --- a/apps/dav/lib/carddav/carddavbackend.php +++ b/apps/dav/lib/carddav/carddavbackend.php @@ -343,7 +343,7 @@ class CardDavBackend implements BackendInterface, SyncSupport { * If the backend supports this, it may allow for some speed-ups. * * @param mixed $addressBookId - * @param array $uris + * @param string[] $uris * @return array */ function getMultipleCards($addressBookId, array $uris) { @@ -390,7 +390,7 @@ class CardDavBackend implements BackendInterface, SyncSupport { * @param mixed $addressBookId * @param string $cardUri * @param string $cardData - * @return string|null + * @return string */ function createCard($addressBookId, $cardUri, $cardData) { $etag = md5($cardData); @@ -435,7 +435,7 @@ class CardDavBackend implements BackendInterface, SyncSupport { * @param mixed $addressBookId * @param string $cardUri * @param string $cardData - * @return string|null + * @return string */ function updateCard($addressBookId, $cardUri, $cardData) { diff --git a/apps/dav/lib/connector/sabre/auth.php b/apps/dav/lib/connector/sabre/auth.php index 0394bfd6772..f9a39799046 100644 --- a/apps/dav/lib/connector/sabre/auth.php +++ b/apps/dav/lib/connector/sabre/auth.php @@ -150,7 +150,7 @@ class Auth extends AbstractBasic { /** * @param \Sabre\DAV\Server $server - * @param $realm + * @param string $realm * @return bool */ private function auth(\Sabre\DAV\Server $server, $realm) { diff --git a/apps/dav/lib/connector/sabre/fakelockerplugin.php b/apps/dav/lib/connector/sabre/fakelockerplugin.php index 493d3b0ade4..b9d1a30a041 100644 --- a/apps/dav/lib/connector/sabre/fakelockerplugin.php +++ b/apps/dav/lib/connector/sabre/fakelockerplugin.php @@ -59,7 +59,7 @@ class FakeLockerPlugin extends ServerPlugin { * Indicate that we support LOCK and UNLOCK * * @param string $path - * @return array + * @return string[] */ public function getHTTPMethods($path) { return [ @@ -71,7 +71,7 @@ class FakeLockerPlugin extends ServerPlugin { /** * Indicate that we support locking * - * @return array + * @return integer[] */ function getFeatures() { return [2]; diff --git a/apps/dav/lib/connector/sabre/file.php b/apps/dav/lib/connector/sabre/file.php index a0c35fb2baf..ef7b9891dc9 100644 --- a/apps/dav/lib/connector/sabre/file.php +++ b/apps/dav/lib/connector/sabre/file.php @@ -213,6 +213,9 @@ class File extends Node implements IFile { return '"' . $this->info->getEtag() . '"'; } + /** + * @param string $path + */ private function emitPreHooks($exists, $path = null) { if (is_null($path)) { $path = $this->path; @@ -238,6 +241,9 @@ class File extends Node implements IFile { return $run; } + /** + * @param string $path + */ private function emitPostHooks($exists, $path = null) { if (is_null($path)) { $path = $this->path; @@ -260,7 +266,7 @@ class File extends Node implements IFile { /** * Returns the data * - * @return string|resource + * @return resource * @throws Forbidden * @throws ServiceUnavailable */ @@ -314,7 +320,7 @@ class File extends Node implements IFile { * * If null is returned, we'll assume application/octet-stream * - * @return mixed + * @return string */ public function getContentType() { $mimeType = $this->info->getMimetype(); diff --git a/apps/dav/lib/connector/sabre/lockplugin.php b/apps/dav/lib/connector/sabre/lockplugin.php index 8032d2b3fbf..d770b141eb9 100644 --- a/apps/dav/lib/connector/sabre/lockplugin.php +++ b/apps/dav/lib/connector/sabre/lockplugin.php @@ -27,7 +27,6 @@ use OCP\Lock\ILockingProvider; use OCP\Lock\LockedException; use Sabre\DAV\Exception\NotFound; use Sabre\DAV\ServerPlugin; -use Sabre\DAV\Tree; use Sabre\HTTP\RequestInterface; class LockPlugin extends ServerPlugin { diff --git a/apps/dav/lib/connector/sabre/node.php b/apps/dav/lib/connector/sabre/node.php index daf82ba6f0d..c4e0614077f 100644 --- a/apps/dav/lib/connector/sabre/node.php +++ b/apps/dav/lib/connector/sabre/node.php @@ -178,7 +178,7 @@ abstract class Node implements \Sabre\DAV\INode { /** * Returns the size of the node, in bytes * - * @return int|float + * @return integer */ public function getSize() { return $this->info->getSize(); @@ -207,14 +207,14 @@ abstract class Node implements \Sabre\DAV\INode { } /** - * @return string + * @return integer */ public function getInternalFileId() { return $this->info->getId(); } /** - * @return string|null + * @return string */ public function getDavPermissions() { $p = ''; diff --git a/apps/dav/lib/connector/sabre/principal.php b/apps/dav/lib/connector/sabre/principal.php index 35215e1f63c..7fb14c031f9 100644 --- a/apps/dav/lib/connector/sabre/principal.php +++ b/apps/dav/lib/connector/sabre/principal.php @@ -168,7 +168,7 @@ class Principal implements \Sabre\DAVACL\PrincipalBackend\BackendInterface { * The principals should be passed as a list of uri's. * * @param string $principal - * @param array $members + * @param string[] $members * @throws \Sabre\DAV\Exception */ public function setGroupMemberSet($principal, array $members) { diff --git a/apps/dav/tests/unit/connector/sabre/file.php b/apps/dav/tests/unit/connector/sabre/file.php index 399634f8bee..0a52299cec7 100644 --- a/apps/dav/tests/unit/connector/sabre/file.php +++ b/apps/dav/tests/unit/connector/sabre/file.php @@ -41,6 +41,9 @@ class File extends \Test\TestCase { parent::tearDown(); } + /** + * @param string $string + */ private function getStream($string) { $stream = fopen('php://temp', 'r+'); fwrite($stream, $string); @@ -239,7 +242,7 @@ class File extends \Test\TestCase { * @param string $path path to put the file into * @param string $viewRoot root to use for the view * - * @return result of the PUT operaiton which is usually the etag + * @return null|string of the PUT operaiton which is usually the etag */ private function doPut($path, $viewRoot = null) { $view = \OC\Files\Filesystem::getView(); diff --git a/apps/dav/tests/unit/connector/sabre/filesplugin.php b/apps/dav/tests/unit/connector/sabre/filesplugin.php index 2e3338fefa1..b33c8340f72 100644 --- a/apps/dav/tests/unit/connector/sabre/filesplugin.php +++ b/apps/dav/tests/unit/connector/sabre/filesplugin.php @@ -55,6 +55,9 @@ class FilesPlugin extends \Test\TestCase { $this->plugin->initialize($this->server); } + /** + * @param string $class + */ private function createTestNode($class) { $node = $this->getMockBuilder($class) ->disableOriginalConstructor() diff --git a/apps/dav/tests/unit/connector/sabre/requesttest/auth.php b/apps/dav/tests/unit/connector/sabre/requesttest/auth.php index 41b554d11db..02b64ab070b 100644 --- a/apps/dav/tests/unit/connector/sabre/requesttest/auth.php +++ b/apps/dav/tests/unit/connector/sabre/requesttest/auth.php @@ -41,7 +41,7 @@ class Auth implements BackendInterface { * * @param \Sabre\DAV\Server $server * @param string $realm - * @return bool + * @return boolean|null */ function authenticate(\Sabre\DAV\Server $server, $realm) { $userSession = \OC::$server->getUserSession(); @@ -61,7 +61,7 @@ class Auth implements BackendInterface { * * If nobody is currently logged in, this method should return null. * - * @return string|null + * @return string */ function getCurrentUser() { return $this->user; |