[Pkg-owncloud-commits] [owncloud] 162/223: Fix setupFromToken when a password is set

David Prévot taffit at moszumanska.debian.org
Sun Jun 22 01:54:20 UTC 2014


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch master
in repository owncloud.

commit 9c2918a62693b4316638eaefcd6cf5ad3c58979f
Author: Robin Appelman <icewind at owncloud.com>
Date:   Mon Jun 16 16:09:56 2014 +0200

    Fix setupFromToken when a password is set
---
 apps/files_sharing/lib/helper.php | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/apps/files_sharing/lib/helper.php b/apps/files_sharing/lib/helper.php
index a86cb83..34de3a9 100644
--- a/apps/files_sharing/lib/helper.php
+++ b/apps/files_sharing/lib/helper.php
@@ -16,7 +16,7 @@ class Helper {
 	public static function setupFromToken($token, $relativePath = null, $password = null) {
 		\OC_User::setIncognitoMode(true);
 
-		$linkItem = \OCP\Share::getShareByToken($token);
+		$linkItem = \OCP\Share::getShareByToken($token, !$password);
 		if($linkItem === false || ($linkItem['item_type'] !== 'file' && $linkItem['item_type'] !== 'folder')) {
 			\OC_Response::setStatus(404);
 			\OC_Log::write('core-preview', 'Passed token parameter is not valid', \OC_Log::DEBUG);

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/owncloud.git



More information about the Pkg-owncloud-commits mailing list