summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorThomas Müller <thomas.mueller@tmit.eu>2013-11-08 11:24:19 +0100
committerThomas Müller <thomas.mueller@tmit.eu>2013-11-08 11:24:19 +0100
commitf93dcc5d77ca3f27e4b40903ac602fdc787521d9 (patch)
treeb83cfb71ceafa56b1c4b7e38d481ad10ed50068e /lib
parent4459d964d6af1f9a1c12e3132b8609fc0f40dc98 (diff)
downloadnextcloud-server-f93dcc5d77ca3f27e4b40903ac602fdc787521d9.tar.gz
nextcloud-server-f93dcc5d77ca3f27e4b40903ac602fdc787521d9.zip
the filesystem has to be initialized once we know the user
Diffstat (limited to 'lib')
-rw-r--r--lib/private/api.php8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/private/api.php b/lib/private/api.php
index 7e69a6a77d2..eac4a825e07 100644
--- a/lib/private/api.php
+++ b/lib/private/api.php
@@ -245,6 +245,10 @@ class OC_API {
$return = OC_User::login($authUser, $authPw);
if ($return === true) {
self::$logoutRequired = true;
+
+ // initialize the user's filesystem
+ \OC_Util::setUpFS(\OC_User::getUser());
+
return $authUser;
}
@@ -252,6 +256,10 @@ class OC_API {
$loggedIn = OC_User::isLoggedIn();
$ocsApiRequest = isset($_SERVER['HTTP_OCS_APIREQUEST']) ? $_SERVER['HTTP_OCS_APIREQUEST'] === 'true' : false;
if ($loggedIn === true && $ocsApiRequest) {
+
+ // initialize the user's filesystem
+ \OC_Util::setUpFS(\OC_User::getUser());
+
return OC_User::getUser();
}