diff options
author | Björn Schießle <schiessle@owncloud.com> | 2016-04-19 16:59:08 +0200 |
---|---|---|
committer | Björn Schießle <schiessle@owncloud.com> | 2016-04-19 17:04:21 +0200 |
commit | a3381b1d0c69ca279c4b218d870dc5874a934793 (patch) | |
tree | 5f969c77319672a1176c7e04b1af930273123298 /apps/encryption/hooks | |
parent | b441d3dcb32ef2cf2aa0e088ed320996b67e8fd5 (diff) | |
download | nextcloud-server-a3381b1d0c69ca279c4b218d870dc5874a934793.tar.gz nextcloud-server-a3381b1d0c69ca279c4b218d870dc5874a934793.zip |
we need to initialize the mount points of the given user before we recover
access to his files
Diffstat (limited to 'apps/encryption/hooks')
-rw-r--r-- | apps/encryption/hooks/userhooks.php | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/apps/encryption/hooks/userhooks.php b/apps/encryption/hooks/userhooks.php index 62acd168909..bde4d5869b4 100644 --- a/apps/encryption/hooks/userhooks.php +++ b/apps/encryption/hooks/userhooks.php @@ -24,6 +24,7 @@ namespace OCA\Encryption\Hooks; +use OC\Files\Filesystem; use OCP\IUserManager; use OCP\Util as OCUtil; use OCA\Encryption\Hooks\Contracts\IHook; @@ -243,6 +244,7 @@ class UserHooks implements IHook { // used to decrypt it has changed } else { // admin changed the password for a different user, create new keys and re-encrypt file keys $user = $params['uid']; + $this->initMountPoints($user); $recoveryPassword = isset($params['recoveryPassword']) ? $params['recoveryPassword'] : null; // we generate new keys if... @@ -281,6 +283,15 @@ class UserHooks implements IHook { } } + /** + * init mount points for given user + * + * @param string $user + * @throws \OC\User\NoUserException + */ + protected function initMountPoints($user) { + Filesystem::initMountPoints($user); + } /** |