From 6848b069c9f33a164c8a5ab180a9a7f40802527b Mon Sep 17 00:00:00 2001 From: Thomas Tanghus Date: Tue, 24 Apr 2012 00:26:33 +0200 Subject: [PATCH] OC_App::getStorage() failed if app dir didn't exist. --- lib/app.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/app.php b/lib/app.php index 9f7d23872f3..29653775253 100755 --- a/lib/app.php +++ b/lib/app.php @@ -519,6 +519,10 @@ class OC_App{ public static function getStorage($appid){ if(OC_App::isEnabled($appid)){//sanity check if(OC_User::isLoggedIn()){ + $view = new OC_FilesystemView('/'.OC_User::getUser()); + if(!$view->file_exists($appid)) { + $view->mkdir($appid); + } return new OC_FilesystemView('/'.OC_User::getUser().'/'.$appid); }else{ OC_Log::write('core','Can\'t get app storage, app, user not logged in',OC_Log::ERROR); -- 2.39.5