Skip to content

Commit 53acec7

Browse files
authored
Merge pull request #6894 from nextcloud/backport/6893/stable31
2 parents 3a454b7 + 5ca18b1 commit 53acec7

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

lib/Sharing/DeckShareProvider.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -270,15 +270,15 @@ private function createShareObject(array $data): IShare {
270270

271271
private function applyBoardPermission($share, $permissions, $userId) {
272272
try {
273-
$this->permissionService->checkPermission($this->cardMapper, $share->getSharedWith(), Acl::PERMISSION_EDIT, $userId);
273+
$this->permissionService->checkPermission($this->cardMapper, $share->getSharedWith(), Acl::PERMISSION_EDIT, $userId, true);
274274
} catch (NoPermissionException $e) {
275275
$permissions &= Constants::PERMISSION_ALL - Constants::PERMISSION_UPDATE;
276276
$permissions &= Constants::PERMISSION_ALL - Constants::PERMISSION_CREATE;
277277
$permissions &= Constants::PERMISSION_ALL - Constants::PERMISSION_DELETE;
278278
}
279279

280280
try {
281-
$this->permissionService->checkPermission($this->cardMapper, $share->getSharedWith(), Acl::PERMISSION_SHARE, $userId);
281+
$this->permissionService->checkPermission($this->cardMapper, $share->getSharedWith(), Acl::PERMISSION_SHARE, $userId, true);
282282
} catch (NoPermissionException $e) {
283283
$permissions &= Constants::PERMISSION_ALL - Constants::PERMISSION_SHARE;
284284
}
@@ -747,6 +747,8 @@ public function getSharedWith($userId, $shareType, $node, $limit, $offset): arra
747747
$qb->expr()->eq('s.item_type', $qb->createNamedParameter('folder'))
748748
));
749749

750+
$qb->andWhere($qb->expr()->eq('dc.deleted_at', $qb->createNamedParameter(0, IQueryBuilder::PARAM_INT)));
751+
750752
$cursor = $qb->execute();
751753
while ($data = $cursor->fetch()) {
752754
if (!$this->isAccessibleResult($data)) {

0 commit comments

Comments
 (0)