diff options
Diffstat (limited to 'lib/util.php')
-rwxr-xr-x | lib/util.php | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/lib/util.php b/lib/util.php index 25632ac1ea2..d1752ecba0a 100755 --- a/lib/util.php +++ b/lib/util.php @@ -320,6 +320,23 @@ class OC_Util { } /** + * @brief check if there are still some encrypted files stored + * @return boolean + */ + public static function encryptedFiles() { + //check if encryption was enabled in the past + $encryptedFiles = false; + if (OC_App::isEnabled('files_encryption') === false) { + $view = new OC\Files\View('/' . OCP\User::getUser()); + if ($view->file_exists('/files_encryption/keyfiles')) { + $encryptedFiles = true; + } + } + + return $encryptedFiles; + } + + /** * Check for correct file permissions of data directory * @return array arrays with error messages and hints */ |