diff options
author | Robin McCorkell <rmccorkell@karoshi.org.uk> | 2015-01-16 18:31:15 +0000 |
---|---|---|
committer | Robin McCorkell <rmccorkell@karoshi.org.uk> | 2015-01-16 20:30:43 +0000 |
commit | 2b99fc76eced32c740a9f87d48354e0ffdc57f45 (patch) | |
tree | 91d1b951b175222a61d28b29d29c75031efe0b27 /apps | |
parent | 3465604cf9ed20b169da9c1a8bbd31a9afcf9183 (diff) | |
download | nextcloud-server-2b99fc76eced32c740a9f87d48354e0ffdc57f45.tar.gz nextcloud-server-2b99fc76eced32c740a9f87d48354e0ffdc57f45.zip |
Cleanup of PHPDoc return types
Diffstat (limited to 'apps')
-rw-r--r-- | apps/files_sharing/lib/cache.php | 8 | ||||
-rw-r--r-- | apps/files_sharing/lib/controllers/sharecontroller.php | 2 | ||||
-rw-r--r-- | apps/files_sharing/lib/sharedstorage.php | 2 | ||||
-rw-r--r-- | apps/user_ldap/lib/access.php | 14 | ||||
-rw-r--r-- | apps/user_ldap/lib/wizard.php | 20 | ||||
-rw-r--r-- | apps/user_ldap/user_ldap.php | 2 |
6 files changed, 24 insertions, 24 deletions
diff --git a/apps/files_sharing/lib/cache.php b/apps/files_sharing/lib/cache.php index 21f807f3533..e0737834812 100644 --- a/apps/files_sharing/lib/cache.php +++ b/apps/files_sharing/lib/cache.php @@ -45,7 +45,7 @@ class Shared_Cache extends Cache { * Get the source cache of a shared file or folder * * @param string $target Shared target file path - * @return \OC\Files\Cache\Cache + * @return \OC\Files\Cache\Cache|false */ private function getSourceCache($target) { if ($target === false || $target === $this->storage->getMountPoint()) { @@ -82,7 +82,7 @@ class Shared_Cache extends Cache { * get the stored metadata of a file or folder * * @param string|int $file - * @return array + * @return array|false */ public function get($file) { if (is_string($file)) { @@ -148,7 +148,7 @@ class Shared_Cache extends Cache { * get the metadata of all files stored in $folder * * @param string $folderId - * @return array + * @return array|false */ public function getFolderContentsById($folderId) { $cache = $this->getSourceCache(''); @@ -178,7 +178,7 @@ class Shared_Cache extends Cache { * @param string $file * @param array $data * - * @return int file id + * @return int|false file id */ public function put($file, array $data) { $file = ($file === false) ? '' : $file; diff --git a/apps/files_sharing/lib/controllers/sharecontroller.php b/apps/files_sharing/lib/controllers/sharecontroller.php index 69de717611c..3534ba179f1 100644 --- a/apps/files_sharing/lib/controllers/sharecontroller.php +++ b/apps/files_sharing/lib/controllers/sharecontroller.php @@ -131,7 +131,7 @@ class ShareController extends Controller { * * @param string $token * @param string $path - * @return TemplateResponse + * @return TemplateResponse|RedirectResponse */ public function showShare($token, $path = '') { \OC_User::setIncognitoMode(true); diff --git a/apps/files_sharing/lib/sharedstorage.php b/apps/files_sharing/lib/sharedstorage.php index d992f8f70b4..ccfbebddb29 100644 --- a/apps/files_sharing/lib/sharedstorage.php +++ b/apps/files_sharing/lib/sharedstorage.php @@ -80,7 +80,7 @@ class Shared extends \OC\Files\Storage\Common implements ISharedStorage { /** * Get the source file path for a shared file * @param string $target Shared target file path - * @return string source file path or false if not found + * @return string|false source file path or false if not found */ public function getSourcePath($target) { $source = $this->getFile($target); diff --git a/apps/user_ldap/lib/access.php b/apps/user_ldap/lib/access.php index 0fb968cebe7..498a3ae923f 100644 --- a/apps/user_ldap/lib/access.php +++ b/apps/user_ldap/lib/access.php @@ -303,7 +303,7 @@ class Access extends LDAPUtility implements user\IUserTools { /** * returns the LDAP DN for the given internal ownCloud name of the user * @param string $name the ownCloud name in question - * @return string with the LDAP DN on success, otherwise false + * @return string|false with the LDAP DN on success, otherwise false */ public function username2dn($name) { $fdn = $this->userMapper->getDNbyName($name); @@ -322,7 +322,7 @@ class Access extends LDAPUtility implements user\IUserTools { * returns the internal ownCloud name for the given LDAP DN of the group, false on DN outside of search DN or failure * @param string $fdn the dn of the group object * @param string $ldapName optional, the display name of the object - * @return string with the name to use in ownCloud, false on DN outside of search DN + * @return string|false with the name to use in ownCloud, false on DN outside of search DN */ public function dn2groupname($fdn, $ldapName = null) { //To avoid bypassing the base DN settings under certain circumstances @@ -339,7 +339,7 @@ class Access extends LDAPUtility implements user\IUserTools { * returns the internal ownCloud name for the given LDAP DN of the user, false on DN outside of search DN or failure * @param string $dn the dn of the user object * @param string $ldapName optional, the display name of the object - * @return string with with the name to use in ownCloud + * @return string|false with with the name to use in ownCloud */ public function dn2username($fdn, $ldapName = null) { //To avoid bypassing the base DN settings under certain circumstances @@ -357,7 +357,7 @@ class Access extends LDAPUtility implements user\IUserTools { * @param string $dn the dn of the user object * @param string $ldapName optional, the display name of the object * @param bool $isUser optional, whether it is a user object (otherwise group assumed) - * @return string with with the name to use in ownCloud + * @return string|false with with the name to use in ownCloud */ public function dn2ocname($fdn, $ldapName = null, $isUser = true) { if($isUser) { @@ -508,7 +508,7 @@ class Access extends LDAPUtility implements user\IUserTools { /** * creates a unique name for internal ownCloud use for users. Don't call it directly. * @param string $name the display name of the object - * @return string with with the name to use in ownCloud or false if unsuccessful + * @return string|false with with the name to use in ownCloud or false if unsuccessful * * Instead of using this method directly, call * createAltInternalOwnCloudName($name, true) @@ -530,7 +530,7 @@ class Access extends LDAPUtility implements user\IUserTools { /** * creates a unique name for internal ownCloud use for groups. Don't call it directly. * @param string $name the display name of the object - * @return string with with the name to use in ownCloud or false if unsuccessful. + * @return string|false with with the name to use in ownCloud or false if unsuccessful. * * Instead of using this method directly, call * createAltInternalOwnCloudName($name, false) @@ -569,7 +569,7 @@ class Access extends LDAPUtility implements user\IUserTools { * creates a unique name for internal ownCloud use. * @param string $name the display name of the object * @param boolean $isUser whether name should be created for a user (true) or a group (false) - * @return string with with the name to use in ownCloud or false if unsuccessful + * @return string|false with with the name to use in ownCloud or false if unsuccessful */ private function createAltInternalOwnCloudName($name, $isUser) { $originalTTL = $this->connection->ldapCacheTTL; diff --git a/apps/user_ldap/lib/wizard.php b/apps/user_ldap/lib/wizard.php index 2e4507a2585..ed9188bc880 100644 --- a/apps/user_ldap/lib/wizard.php +++ b/apps/user_ldap/lib/wizard.php @@ -110,7 +110,7 @@ class Wizard extends LDAPUtility { return false; } $groupsTotal = ($groupsTotal !== false) ? $groupsTotal : 0; - $output = self::$l->n('%s group found', '%s groups found', $groupsTotal, $groupsTotal); + $output = self::$l->n('%s group found', '%s groups found', $groupsTotal, array($groupsTotal)); $this->result->addChange('ldap_group_count', $output); return $this->result; } @@ -124,7 +124,7 @@ class Wizard extends LDAPUtility { $usersTotal = $this->countEntries($filter, 'users'); $usersTotal = ($usersTotal !== false) ? $usersTotal : 0; - $output = self::$l->n('%s user found', '%s users found', $usersTotal, $usersTotal); + $output = self::$l->n('%s user found', '%s users found', $usersTotal, array($usersTotal)); $this->result->addChange('ldap_user_count', $output); return $this->result; } @@ -314,7 +314,7 @@ class Wizard extends LDAPUtility { /** * detects the available LDAP attributes - * @return array The instance's WizardResult instance + * @return array|false The instance's WizardResult instance * @throws \Exception */ private function getUserAttributes() { @@ -348,7 +348,7 @@ class Wizard extends LDAPUtility { /** * detects the available LDAP groups - * @return WizardResult the instance's WizardResult instance + * @return WizardResult|false the instance's WizardResult instance */ public function determineGroupsForGroups() { return $this->determineGroups('ldap_groupfilter_groups', @@ -358,7 +358,7 @@ class Wizard extends LDAPUtility { /** * detects the available LDAP groups - * @return WizardResult the instance's WizardResult instance + * @return WizardResult|false the instance's WizardResult instance */ public function determineGroupsForUsers() { return $this->determineGroups('ldap_userfilter_groups', @@ -370,7 +370,7 @@ class Wizard extends LDAPUtility { * @param string $dbKey * @param string $confKey * @param bool $testMemberOf - * @return WizardResult the instance's WizardResult instance + * @return WizardResult|false the instance's WizardResult instance * @throws \Exception */ private function determineGroups($dbKey, $confKey, $testMemberOf = true) { @@ -467,7 +467,7 @@ class Wizard extends LDAPUtility { /** * Detects the available object classes - * @return WizardResult the instance's WizardResult instance + * @return WizardResult|false the instance's WizardResult instance * @throws \Exception */ public function determineGroupObjectClasses() { @@ -524,7 +524,7 @@ class Wizard extends LDAPUtility { } /** - * @return WizardResult + * @return WizardResult|false * @throws \Exception */ public function getGroupFilter() { @@ -548,7 +548,7 @@ class Wizard extends LDAPUtility { } /** - * @return WizardResult + * @return WizardResult|false * @throws \Exception */ public function getUserListFilter() { @@ -1146,7 +1146,7 @@ class Wizard extends LDAPUtility { * Configuration class * @param bool $po whether the objectClass with most result entries * shall be pre-selected via the result - * @return array, list of found items. + * @return array|false list of found items. * @throws \Exception */ private function determineFeature($objectclasses, $attr, $dbkey, $confkey, $po = false) { diff --git a/apps/user_ldap/user_ldap.php b/apps/user_ldap/user_ldap.php index 051e760105b..270e94121d5 100644 --- a/apps/user_ldap/user_ldap.php +++ b/apps/user_ldap/user_ldap.php @@ -303,7 +303,7 @@ class USER_LDAP extends BackendUtility implements \OCP\IUserBackend, \OCP\UserIn /** * get display name of the user * @param string $uid user ID of the user - * @return string display name + * @return string|false display name */ public function getDisplayName($uid) { if(!$this->userExists($uid)) { |