Fixes retargeting a share of a deleted source

Fixes #1862

We tried to construct the actual node. While this node was no longer
available. This work around makes sure that we don't try to do this.

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
This commit is contained in:
Roeland Jago Douma 2016-11-11 10:35:04 +01:00
parent 1e60c5a164
commit b6284d1664
No known key found for this signature in database
GPG Key ID: 1E152838F164D13B
1 changed files with 3 additions and 3 deletions

View File

@ -434,9 +434,9 @@ class DefaultShareProvider implements IShareProvider {
'uid_owner' => $qb->createNamedParameter($share->getShareOwner()),
'uid_initiator' => $qb->createNamedParameter($share->getSharedBy()),
'parent' => $qb->createNamedParameter($share->getId()),
'item_type' => $qb->createNamedParameter($share->getNode() instanceof File ? 'file' : 'folder'),
'item_source' => $qb->createNamedParameter($share->getNode()->getId()),
'file_source' => $qb->createNamedParameter($share->getNode()->getId()),
'item_type' => $qb->createNamedParameter($share->getNodeType()),
'item_source' => $qb->createNamedParameter($share->getNodeId()),
'file_source' => $qb->createNamedParameter($share->getNodeId()),
'file_target' => $qb->createNamedParameter($share->getTarget()),
'permissions' => $qb->createNamedParameter($share->getPermissions()),
'stime' => $qb->createNamedParameter($share->getShareTime()->getTimestamp()),