summaryrefslogtreecommitdiffstats
path: root/lib/private/Share20/DefaultShareProvider.php
diff options
context:
space:
mode:
authorBjoern Schiessle <bjoern@schiessle.org>2017-03-28 15:11:07 +0200
committerBjoern Schiessle <bjoern@schiessle.org>2017-04-03 10:20:49 +0200
commit0d5147bd492e11dcb1ed264bcc27d21dc026c6f1 (patch)
tree987445dafba0171b933727e6b4060ba7ad4845e6 /lib/private/Share20/DefaultShareProvider.php
parentd0eefd17d3c47de8d13d41e57a2a6966af94428f (diff)
downloadnextcloud-server-0d5147bd492e11dcb1ed264bcc27d21dc026c6f1.tar.gz
nextcloud-server-0d5147bd492e11dcb1ed264bcc27d21dc026c6f1.zip
add new password column to the share table in order to set passwords for share by mails
Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
Diffstat (limited to 'lib/private/Share20/DefaultShareProvider.php')
-rw-r--r--lib/private/Share20/DefaultShareProvider.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/private/Share20/DefaultShareProvider.php b/lib/private/Share20/DefaultShareProvider.php
index e4ae26be13d..cf7666f99e7 100644
--- a/lib/private/Share20/DefaultShareProvider.php
+++ b/lib/private/Share20/DefaultShareProvider.php
@@ -240,7 +240,7 @@ class DefaultShareProvider implements IShareProvider {
$qb = $this->dbConn->getQueryBuilder();
$qb->update('share')
->where($qb->expr()->eq('id', $qb->createNamedParameter($share->getId())))
- ->set('share_with', $qb->createNamedParameter($share->getPassword()))
+ ->set('password', $qb->createNamedParameter($share->getPassword()))
->set('uid_owner', $qb->createNamedParameter($share->getShareOwner()))
->set('uid_initiator', $qb->createNamedParameter($share->getSharedBy()))
->set('permissions', $qb->createNamedParameter($share->getPermissions()))
@@ -646,7 +646,7 @@ class DefaultShareProvider implements IShareProvider {
// exclude shares leading to trashbin on home storages
$pathSections = explode('/', $data['path'], 2);
// FIXME: would not detect rare md5'd home storage case properly
- if ($pathSections[0] !== 'files'
+ if ($pathSections[0] !== 'files'
&& in_array(explode(':', $data['storage_string_id'], 2)[0], array('home', 'object'))) {
return false;
}
@@ -838,7 +838,7 @@ class DefaultShareProvider implements IShareProvider {
} else if ($share->getShareType() === \OCP\Share::SHARE_TYPE_GROUP) {
$share->setSharedWith($data['share_with']);
} else if ($share->getShareType() === \OCP\Share::SHARE_TYPE_LINK) {
- $share->setPassword($data['share_with']);
+ $share->setPassword($data['password']);
$share->setToken($data['token']);
}