Do not expose user data in exceptions & fix typo
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
This commit is contained in:
parent
889e0a574b
commit
8653d14862
|
@ -351,7 +351,7 @@ class Root extends Folder implements IRootFolder {
|
||||||
|
|
||||||
if (is_null($userObject)) {
|
if (is_null($userObject)) {
|
||||||
\OCP\Util::writeLog('files', 'Backends provided no user object for ' . $userId, \OCP\Util::ERROR);
|
\OCP\Util::writeLog('files', 'Backends provided no user object for ' . $userId, \OCP\Util::ERROR);
|
||||||
throw new \OC\User\NoUserException('Backends provided no user object for ' . $userId);
|
throw new \OC\User\NoUserException('Backends provided no user object');
|
||||||
}
|
}
|
||||||
|
|
||||||
$userId = $userObject->getUID();
|
$userId = $userObject->getUID();
|
||||||
|
|
|
@ -139,9 +139,9 @@ class Share extends Constants {
|
||||||
$userManager = \OC::$server->getUserManager();
|
$userManager = \OC::$server->getUserManager();
|
||||||
$userObject = $userManager->get($ownerUser);
|
$userObject = $userManager->get($ownerUser);
|
||||||
|
|
||||||
if (is_null($ownerUser)) {
|
if (is_null($userObject)) {
|
||||||
\OCP\Util::writeLog('files', ' Backends provided no user object for ' . $ownerUser, \OCP\Util::ERROR);
|
\OCP\Util::writeLog('files', ' Backends provided no user object for ' . $ownerUser, \OCP\Util::ERROR);
|
||||||
throw new \OC\User\NoUserException('Backends provided no user object for ' . $ownerUser);
|
throw new \OC\User\NoUserException('Backends provided no user object');
|
||||||
}
|
}
|
||||||
|
|
||||||
$ownerUser = $userObject->getUID();
|
$ownerUser = $userObject->getUID();
|
||||||
|
|
Loading…
Reference in New Issue