Repository navigation
Closed
Labels
Description
Describe the bug
When an accepted share is declined, the resource still exists in the Shares folder
Steps to reproduce
Steps to reproduce the behavior:
- create two users
uu1anduu2 - upload a file
textfile0.txtwith useruu1 - share
textfile0.txtwith useruu2 uu2accepts the last received share
curl -k -u uu2:uu2 -XPOST https://localhost:9200/ocs/v2.php/apps/files_sharing/api/v1/shares/pending/7e00bd51-8cfc-41f9-91a9-eadbfd9c3764\?format\=json | jq
- now
uu2declines the accepted share
curl -k -u uu2:uu2 -XDELETE https://localhost:9200/ocs/v2.php/apps/files_sharing/api/v1/shares/pending/7e00bd51-8cfc-41f9-91a9-eadbfd9c3764\?format\=json | jq
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 922 100 922 0 0 23641 0 --:--:-- --:--:-- --:--:-- 23641
{
"ocs": {
"meta": {
"status": "ok",
"statuscode": 200,
"message": "OK"
},
"data": [
{
"id": "7e00bd51-8cfc-41f9-91a9-eadbfd9c3764",
"share_type": 0,
"uid_owner": "uu1",
"displayname_owner": "uu1",
"additional_info_owner": "[email protected]",
"permissions": 19,
"stime": 1623069539,
"parent": "",
"expiration": "",
"token": "",
"uid_file_owner": "uu1",
"displayname_file_owner": "uu1",
"additional_info_file_owner": "[email protected]",
"state": 2,
"path": "/textfile0.txt",
"item_type": "file",
"mimetype": "text/plain",
"storage_id": "1284d238-aa92-42ce-bdc4-0b0000009157",
"storage": 0,
"item_source": "MTI4NGQyMzgtYWE5Mi00MmNlLWJkYzQtMGIwMDAwMDA5MTU3OjgzNmJjZjI3LWM4MzQtNGJmNi05NjA5LTM2NGFiNWUyMGNkYg==",
"file_source": "MTI4NGQyMzgtYWE5Mi00MmNlLWJkYzQtMGIwMDAwMDA5MTU3OjgzNmJjZjI3LWM4MzQtNGJmNi05NjA5LTM2NGFiNWUyMGNkYg==",
"file_parent": "",
"file_target": "/textfile0.txt",
"share_with": "uu2",
"share_with_displayname": "uu2",
"share_with_additional_info": "[email protected]",
"mail_send": 0,
"name": ""
}
]
}
}
Expected behavior
textfile0.txtshould be gone from the list
Actual behavior
- still exists in the list
Request:
curl -k -u uu2:uu2 -XPROPFIND https://localhost:9200/remote.php/webdav/Shares/ -v | xmllint --format -
Response:
<?xml version="1.0" encoding="utf-8"?>
<d:multistatus xmlns:d="DAV:" xmlns:s="http://sabredav.org/ns" xmlns:oc="http://owncloud.org/ns">
<d:response>
<d:href>/remote.php/webdav/Shares/</d:href>
<d:propstat>
<d:prop>
<oc:id>MTI4NGQyMzgtYWE5Mi00MmNlLWJkYzQtMGIwMDAwMDA5MTU3OjUzZGQzZDM1LWYwYjctNDcxOC05ODBjLTA3NzFmYjUyMTZlZA==</oc:id>
<oc:fileid>MTI4NGQyMzgtYWE5Mi00MmNlLWJkYzQtMGIwMDAwMDA5MTU3OjUzZGQzZDM1LWYwYjctNDcxOC05ODBjLTA3NzFmYjUyMTZlZA==</oc:fileid>
<d:getetag>"4df2512e2ccdb3cfdcd0501cdae55e0e"</d:getetag>
<oc:permissions>RDNVCK</oc:permissions>
<d:resourcetype>
<d:collection/>
</d:resourcetype>
<oc:size>0</oc:size>
<d:getlastmodified>Mon, 07 Jun 2021 12:41:26 GMT</d:getlastmodified>
<oc:favorite>0</oc:favorite>
</d:prop>
<d:status>HTTP/1.1 200 OK</d:status>
</d:propstat>
</d:response>
<d:response>
<d:href>/remote.php/webdav/Shares/peace-pegion.png</d:href>
<d:propstat>
<d:prop>
<oc:id>MTI4NGQyMzgtYWE5Mi00MmNlLWJkYzQtMGIwMDAwMDA5MTU3OjI0NTgzZWE4LWE3MzYtNGFmNi04OTkzLWMwOTJjYWEzZjYyYQ==</oc:id>
<oc:fileid>MTI4NGQyMzgtYWE5Mi00MmNlLWJkYzQtMGIwMDAwMDA5MTU3OjI0NTgzZWE4LWE3MzYtNGFmNi04OTkzLWMwOTJjYWEzZjYyYQ==</oc:fileid>
<d:getetag>"d266c452a9bf6d2cd77240a15c697d06"</d:getetag>
<oc:permissions>S</oc:permissions>
<d:resourcetype/>
<d:getcontentlength>124399</d:getcontentlength>
<d:getcontenttype>image/png</d:getcontenttype>
<d:getlastmodified>Mon, 07 Jun 2021 10:53:14 GMT</d:getlastmodified>
<oc:checksums>
<oc:checksum>SHA1:ccf76297cdb6508b33c2d2c0ac1a706c7d52088d MD5:8db6191c3f194b59eeae72a686379dd1 ADLER32:d3bdae1a</oc:checksum>
</oc:checksums>
<oc:favorite>0</oc:favorite>
</d:prop>
<d:status>HTTP/1.1 200 OK</d:status>
</d:propstat>
</d:response>
<d:response>
<d:href>/remote.php/webdav/Shares/textfile0.txt</d:href>
<d:propstat>
<d:prop>
<oc:id>MTI4NGQyMzgtYWE5Mi00MmNlLWJkYzQtMGIwMDAwMDA5MTU3OjgzNmJjZjI3LWM4MzQtNGJmNi05NjA5LTM2NGFiNWUyMGNkYg==</oc:id>
<oc:fileid>MTI4NGQyMzgtYWE5Mi00MmNlLWJkYzQtMGIwMDAwMDA5MTU3OjgzNmJjZjI3LWM4MzQtNGJmNi05NjA5LTM2NGFiNWUyMGNkYg==</oc:fileid>
<d:getetag>"3b47e21b240acb72ffd6974e34895606"</d:getetag>
<oc:permissions>SRNVW</oc:permissions>
<d:resourcetype/>
<d:getcontentlength>1294</d:getcontentlength>
<d:getcontenttype>text/plain; charset=utf-8</d:getcontenttype>
<d:getlastmodified>Mon, 07 Jun 2021 12:38:36 GMT</d:getlastmodified>
<oc:checksums>
<oc:checksum>SHA1:66307efe8008f73993363f820b2016a241d3c1c5 MD5:7c77937919af2b2d936d652e9688bea0 ADLER32:3d8dde24</oc:checksum>
</oc:checksums>
<oc:favorite>0</oc:favorite>
</d:prop>
<d:status>HTTP/1.1 200 OK</d:status>
</d:propstat>
</d:response>
</d:multistatus>
Setup
export OCIS_URL=https://localhost:9200 18:30:22
export STORAGE_HOME_DRIVER=ocis
export STORAGE_USERS_DRIVER=ocis
export STORAGE_DRIVER_OCIS_ROOT=/tmp/ocis/storage/users
export STORAGE_DRIVER_LOCAL_ROOT=/tmp/ocis/local/root
export STORAGE_METADATA_ROOT=/tmp/ocis/metadata
export STORAGE_DRIVER_OWNCLOUD_DATADIR=/tmp/ocis/owncloud/data
export STORAGE_HOME_DATA_SERVER_URL=http://localhost:9155/data
export STORAGE_USERS_DATA_SERVER_URL=http://localhost:9158/data
export STORAGE_SHARING_USER_JSON_FILE=/tmp/ocis/shares.json
export PROXY_ENABLE_BASIC_AUTH=true
export WEB_UI_CONFIG=$HOME/www/ocConfigs/config.json
export IDP_IDENTIFIER_REGISTRATION_CONF=$HOME/www/ocConfigs/idp.yml
export OCIS_LOG_LEVEL=error
export SETTINGS_DATA_PATH=/tmp/ocis/settings
Details
OCIS_VERSION=latest
BRANCH=master
STORAGE_FRONTEND_UPLOAD_DISABLE_TUS=falseAdditional context
Add any other context about the problem here.
Activity
kiranparajuli589 commentedon Jul 2, 2021
already issued at #2112
C0rby commentedon Sep 9, 2021
Has been fixed here: cs3org/reva#1991
kulmann commentedon Sep 9, 2021
Nice! 😍