diff options
author | Thomas Mueller <thomas.mueller@tmit.eu> | 2013-06-01 00:49:06 +0200 |
---|---|---|
committer | Thomas Mueller <thomas.mueller@tmit.eu> | 2013-06-01 00:49:06 +0200 |
commit | 3e00a3603cadf4e9e4b3c87bba0ef604077146fd (patch) | |
tree | 826a15b41b17cd2ba00e9293dd52e310632f703a /lib/user.php | |
parent | 2c69403fd64adc8b5418ce3c719934a352c89035 (diff) | |
download | nextcloud-server-3e00a3603cadf4e9e4b3c87bba0ef604077146fd.tar.gz nextcloud-server-3e00a3603cadf4e9e4b3c87bba0ef604077146fd.zip |
adding PHPDoc comment to getManager()
adding PHPDoc comment for $user within the hooks callbacks
fixing PHPDoc comment on isLoggedIn()
Diffstat (limited to 'lib/user.php')
-rw-r--r-- | lib/user.php | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/lib/user.php b/lib/user.php index 5f8a4cbfce2..a8b642a1630 100644 --- a/lib/user.php +++ b/lib/user.php @@ -47,24 +47,30 @@ class OC_User { \OC_Hook::emit('OC_User', 'pre_createUser', array('run' => true, 'uid' => $uid, 'password' => $password)); }); self::$userSession->listen('\OC\User', 'postCreateUser', function ($user, $password) { + /** @var $user \OC\User\User */ \OC_Hook::emit('OC_User', 'post_createUser', array('uid' => $user->getUID(), 'password' => $password)); }); self::$userSession->listen('\OC\User', 'preDelete', function ($user) { + /** @var $user \OC\User\User */ \OC_Hook::emit('OC_User', 'pre_deleteUser', array('run' => true, 'uid' => $user->getUID())); }); self::$userSession->listen('\OC\User', 'postDelete', function ($user) { + /** @var $user \OC\User\User */ \OC_Hook::emit('OC_User', 'post_deleteUser', array('uid' => $user->getUID())); }); self::$userSession->listen('\OC\User', 'preSetPassword', function ($user, $password, $recoveryPassword) { + /** @var $user \OC\User\User */ OC_Hook::emit('OC_User', 'pre_setPassword', array('run' => true, 'uid' => $user->getUID(), 'password' => $password, 'recoveryPassword' => $recoveryPassword)); }); self::$userSession->listen('\OC\User', 'postSetPassword', function ($user, $password, $recoveryPassword) { + /** @var $user \OC\User\User */ OC_Hook::emit('OC_User', 'post_setPassword', array('run' => true, 'uid' => $user->getUID(), 'password' => $password, 'recoveryPassword' => $recoveryPassword)); }); self::$userSession->listen('\OC\User', 'preLogin', function ($uid, $password) { \OC_Hook::emit('OC_User', 'pre_login', array('run' => true, 'uid' => $uid, 'password' => $password)); }); self::$userSession->listen('\OC\User', 'postLogin', function ($user, $password) { + /** @var $user \OC\User\User */ \OC_Hook::emit('OC_User', 'post_login', array('run' => true, 'uid' => $user->getUID(), 'password' => $password)); }); self::$userSession->listen('\OC\User', 'logout', function () { @@ -74,6 +80,9 @@ class OC_User { return self::$userSession; } + /** + * @return \OC\User\Manager + */ private static function getManager() { return self::getUserSession()->getManager(); } @@ -292,7 +301,7 @@ class OC_User { /** * @brief Check if the user is logged in - * @returns true/false + * @returns bool * * Checks if the user is logged in */ |