aboutsummaryrefslogtreecommitdiffstats
path: root/lib/public/IUserManager.php
diff options
context:
space:
mode:
authorCarl Schwan <carl@carlschwan.eu>2022-05-13 12:59:51 +0200
committerCarl Schwan <carl@carlschwan.eu>2022-05-20 17:14:58 +0200
commit9ec0cb0a90ecdc7f4181ce8399bfe0c3a35842a2 (patch)
treef7e566b31eaa96a1834881043a939eaae45e4495 /lib/public/IUserManager.php
parenteb45a6ca404524bad6416ba3b3a755f9faa5e9b8 (diff)
downloadnextcloud-server-9ec0cb0a90ecdc7f4181ce8399bfe0c3a35842a2.tar.gz
nextcloud-server-9ec0cb0a90ecdc7f4181ce8399bfe0c3a35842a2.zip
Fix psalm issues related to the user backend
- Reflect the actual return value returned by the implementation in the the interface. E.g. IUser|bool -> IUser|false - Remove $hasLoggedIn parameter from private countUser implementation. Replace the two call with the equivalent countSeenUser - getBackend is nuallable, add this to the interface - Use backend interface to make psalm happy about call to undefined methods. Also helps with getting rid at some point of the old implementActions Signed-off-by: Carl Schwan <carl@carlschwan.eu>
Diffstat (limited to 'lib/public/IUserManager.php')
-rw-r--r--lib/public/IUserManager.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/public/IUserManager.php b/lib/public/IUserManager.php
index e5c220af40c..77e2fc21a22 100644
--- a/lib/public/IUserManager.php
+++ b/lib/public/IUserManager.php
@@ -98,7 +98,7 @@ interface IUserManager {
*
* @param string $loginName
* @param string $password
- * @return mixed the User object on success, false otherwise
+ * @return IUser|false the User object on success, false otherwise
* @since 8.0.0
*/
public function checkPassword($loginName, $password);
@@ -141,7 +141,7 @@ interface IUserManager {
* @param string $uid
* @param string $password
* @throws \InvalidArgumentException
- * @return bool|\OCP\IUser the created user or false
+ * @return false|\OCP\IUser the created user or false
* @since 8.0.0
*/
public function createUser($uid, $password);
@@ -157,9 +157,9 @@ interface IUserManager {
public function createUserFromBackend($uid, $password, UserInterface $backend);
/**
- * returns how many users per backend exist (if supported by backend)
+ * Get how many users per backend exist (if supported by backend)
*
- * @return array an array of backend class as key and count number as value
+ * @return array<string, int> an array of backend class name as key and count number as value
* @since 8.0.0
*/
public function countUsers();