This commit is contained in:
Thomas Citharel 2015-07-06 17:59:09 +02:00
parent 9786dbf165
commit a7be947095

View file

@ -266,6 +266,15 @@ class Poche
} }
foreach($entry_ids as $id) { foreach($entry_ids as $id) {
$msg = 'delete link #' . $id; $msg = 'delete link #' . $id;
// deleting tags and tags_entries
$tags = $this->store->retrieveTagsByEntry($id);
foreach ($tags as $tag) {
$this->store->removeTagForEntry($id, $tag['id']);
$this->store->cleanUnusedTag($tag['id']);
}
// deleting pictures
if ($this->store->deleteById($id, $this->user->getId())) { if ($this->store->deleteById($id, $this->user->getId())) {
if (DOWNLOAD_PICTURES) { if (DOWNLOAD_PICTURES) {
Picture::removeDirectory(ABS_PATH . $id); Picture::removeDirectory(ABS_PATH . $id);