]> source.dussan.org Git - nextcloud-server.git/commitdiff
Fix unsharing files also deleting private link, bug fix for oc-251
authorMichael Gapczynski <GapczynskiM@gmail.com>
Wed, 9 May 2012 21:37:42 +0000 (17:37 -0400)
committerMichael Gapczynski <GapczynskiM@gmail.com>
Wed, 9 May 2012 21:38:35 +0000 (17:38 -0400)
apps/files_sharing/lib_share.php

index 912b5ffdf95b615ee56d40cd543cc4e486e1c230..02e4b6e4c26532a5e714cf6d49b84ed8af9c5ef9 100755 (executable)
@@ -385,7 +385,7 @@ class OC_Share {
        public static function unshare($source, $uid_shared_with) {
                $source = self::cleanPath($source);
                $uid_owner = OCP\USER::getUser();
-               $query = OCP\DB::prepare("DELETE FROM *PREFIX*sharing WHERE SUBSTR(source, 1, ?) = ? AND uid_owner = ? AND uid_shared_with ".self::getUsersAndGroups($uid_shared_with));
+               $query = OCP\DB::prepare("DELETE FROM *PREFIX*sharing WHERE SUBSTR(source, 1, ?) = ? AND uid_owner = ? AND uid_shared_with ".self::getUsersAndGroups($uid_shared_with, false));
                $query->execute(array(strlen($source), $source, $uid_owner));
                if ($uid_shared_with != self::PUBLICLINK) {
                        if (OC_Group::groupExists($uid_shared_with)) {