summaryrefslogtreecommitdiffstats
path: root/apps/encryption
diff options
context:
space:
mode:
authorMorris Jobke <hey@morrisjobke.de>2017-10-23 23:47:06 +0200
committerMorris Jobke <hey@morrisjobke.de>2017-10-23 23:47:06 +0200
commit5987099d2a7801d89310dc9e829927a67c1af9d2 (patch)
tree991b9a1b576d6a0f601dd48dac64c470c6dee4cc /apps/encryption
parentdb1096bcfdf2336ccf6aefb70dd902a63ed615db (diff)
downloadnextcloud-server-5987099d2a7801d89310dc9e829927a67c1af9d2.tar.gz
nextcloud-server-5987099d2a7801d89310dc9e829927a67c1af9d2.zip
Remove unneeded check if app is enabled
App code will not be executable if the app is not enabled, because the autoloader refuses to load that class. Signed-off-by: Morris Jobke <hey@morrisjobke.de>
Diffstat (limited to 'apps/encryption')
-rw-r--r--apps/encryption/lib/Hooks/UserHooks.php21
1 files changed, 4 insertions, 17 deletions
diff --git a/apps/encryption/lib/Hooks/UserHooks.php b/apps/encryption/lib/Hooks/UserHooks.php
index e0826e2c7e3..a08796aee54 100644
--- a/apps/encryption/lib/Hooks/UserHooks.php
+++ b/apps/encryption/lib/Hooks/UserHooks.php
@@ -170,11 +170,6 @@ class UserHooks implements IHook {
* @return boolean|null
*/
public function login($params) {
-
- if (!App::isEnabled('encryption')) {
- return true;
- }
-
// ensure filesystem is loaded
if (!\OC\Files\Filesystem::$loaded) {
$this->setupFS($params['uid']);
@@ -200,10 +195,7 @@ class UserHooks implements IHook {
* @param array $params
*/
public function postCreateUser($params) {
-
- if (App::isEnabled('encryption')) {
- $this->userSetup->setupUser($params['uid'], $params['password']);
- }
+ $this->userSetup->setupUser($params['uid'], $params['password']);
}
/**
@@ -213,17 +205,12 @@ class UserHooks implements IHook {
* @note This method should never be called for users using client side encryption
*/
public function postDeleteUser($params) {
-
- if (App::isEnabled('encryption')) {
- $this->keyManager->deletePublicKey($params['uid']);
- }
+ $this->keyManager->deletePublicKey($params['uid']);
}
public function prePasswordReset($params) {
- if (App::isEnabled('encryption')) {
- $user = $params['uid'];
- self::$passwordResetUsers[$user] = true;
- }
+ $user = $params['uid'];
+ self::$passwordResetUsers[$user] = true;
}
public function postPasswordReset($params) {