diff options
author | Sam Tuke <samtuke@owncloud.com> | 2013-04-10 17:37:03 +0200 |
---|---|---|
committer | Sam Tuke <samtuke@owncloud.com> | 2013-04-16 13:22:16 +0200 |
commit | f378a7f572e1da4b24280c1fcbf830e026186c83 (patch) | |
tree | 23c4f621dd087595a0bb2212ac1f66203ee22bc4 /apps/files_encryption/ajax | |
parent | 854b9207878d9c5cd8f0d972f4b16b618beade3a (diff) | |
download | nextcloud-server-f378a7f572e1da4b24280c1fcbf830e026186c83.tar.gz nextcloud-server-f378a7f572e1da4b24280c1fcbf830e026186c83.zip |
Fixed proxy class handing of read / write files
Various work on other classes
Diffstat (limited to 'apps/files_encryption/ajax')
-rw-r--r-- | apps/files_encryption/ajax/adminrecovery.php | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/apps/files_encryption/ajax/adminrecovery.php b/apps/files_encryption/ajax/adminrecovery.php index f22114f8514..cec0cd4ddda 100644 --- a/apps/files_encryption/ajax/adminrecovery.php +++ b/apps/files_encryption/ajax/adminrecovery.php @@ -15,6 +15,8 @@ use OCA\Encryption; \OCP\JSON::checkAppEnabled( 'files_encryption' ); \OCP\JSON::callCheck(); +$return = $doSetup = false; + if ( isset( $_POST['adminEnableRecovery'] ) && $_POST['adminEnableRecovery'] == 1 @@ -47,7 +49,7 @@ if ( // If the recoveryAdmin UID exists but doesn't have admin rights } else { - \OCP\JSON::error(); + $return = false; } @@ -63,10 +65,12 @@ if ( $util->setupServerSide( $_POST['recoveryPassword'] ); // Store the UID in the DB - OC_Appconfig::setValue( 'encryption', 'recoveryAdminUid', $recoveryAdminUid ); + OC_Appconfig::setValue( 'files_encryption', 'recoveryAdminUid', $recoveryAdminUid ); - \OCP\JSON::success(); + $return = true; } -}
\ No newline at end of file +} + +($return) ? OC_JSON::success() : OC_JSON::error();
\ No newline at end of file |