Closed ratikal closed 10 years ago
Please use the issue template: https://raw.github.com/owncloud/core/master/issue_template.md
Also tell us what API functions/endpoints you are using when creating shares.
I am creating an api call that creates a new user, 2 user groups some folders inside the new user home folder and want to share them with the 2 user groups.
First time run as expected. If i run it again and the share I want to make is already made it breaks.
Operating system: Linux mint
Web server: Nginx
Database: Mysql
PHP version: 5.5.3
ownCloud version: 7.0.2 (stable)
Updated from an older ownCloud or fresh install:
List of activated apps:
The content of config/config.php:
Insert your config.php content here
Only difference from the default is default_language..
Are you using external storage, if yes which one: local/smb/sftp/...
no
Are you using encryption: yes/no
no
Browser: curl (term)
Operating system: Linux
Error PHP Sharing 1382 failed, because this item is already shared with hug-group2-admins at /home/nick/htdocs/oc/lib/private/share/share.php#589 2014-11-11T12:16:43+00:00
Error OCP\Share Sharing 1382 failed, because this item is already shared with hug-group2-admins ```
@schiesbn can you help with this ?
@ratikal thanks for the details.
When someone request that api call, app run OC\Share\Share::ShareItem( .. ) to share a folder of the logged user with another user. The second time you try to do the same thing it breaks.
This sounds correct to me. If the file is already shared with a user/group and you try to share it again with the same user/group you get a error that the file is already shared with the user/group. It doesn't make sense to share a file multiple times with the same user/group
I think I found out what my problem is, i have to update some files in my owncloud to be sure.
I have to catch the error to prevent the script from stoping.
My bad its ok, you may close this
no problem, great that you could solve the problem
I am new to owncloud I am writing an app that creates some shares between users and groups through a custom api call. When I try to share something that is already shared the function breaks.
Also when I delete a user or group that shares files or folder the oc_share table keeps the records.
i think it has to do with owncloud and not with my app.