diff options
author | Bartek Przybylski <bart.p.pl@gmail.com> | 2012-01-25 21:15:27 +0100 |
---|---|---|
committer | Bartek Przybylski <bart.p.pl@gmail.com> | 2012-01-25 21:15:27 +0100 |
commit | 63ae4b3dfc9466b8ba5e392a63b7cfb10d6980fc (patch) | |
tree | 516b4d9606b803e424ecc0e614392fdedec8742e /apps/gallery | |
parent | 5172e0a7a388fc2c22c9e10435f0ee2728dc5e36 (diff) | |
download | nextcloud-server-63ae4b3dfc9466b8ba5e392a63b7cfb10d6980fc.tar.gz nextcloud-server-63ae4b3dfc9466b8ba5e392a63b7cfb10d6980fc.zip |
db cleanup after gallery remove
Diffstat (limited to 'apps/gallery')
-rw-r--r-- | apps/gallery/ajax/galleryOp.php | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/apps/gallery/ajax/galleryOp.php b/apps/gallery/ajax/galleryOp.php index f162fe2bc46..0c2674f8859 100644 --- a/apps/gallery/ajax/galleryOp.php +++ b/apps/gallery/ajax/galleryOp.php @@ -34,7 +34,11 @@ function handleRename($oldname, $newname) { function handleRemove($name) { OC_JSON::checkLoggedIn(); + $album_id = OC_Gallery_Album::find(OC_User::getUser(), $name); + $album_id = $album_id->fetchRow(); + $album_id = $album_id['album_id']; OC_Gallery_Album::remove(OC_User::getUser(), $name); + OC_Gallery_Photo::removeByAlbumId($album_id); } function handleGetThumbnails($albumname) { |