]> git.mxchange.org Git - friendica.git/blobdiff - src/Worker/Delivery.php
Restore previous permission comment in Widget\CalendarExport
[friendica.git] / src / Worker / Delivery.php
index dbc0bdb5d0da22a1f746622e7fb446eb6dfad19e..dc6caab3db9c95fe0cdece3100077ed633c7ac4c 100644 (file)
@@ -17,9 +17,7 @@ use Friendica\Protocol\Diaspora;
 use Friendica\Protocol\Email;
 use dba;
 
-require_once 'include/html2plain.php';
 require_once 'include/items.php';
-require_once 'include/bbcode.php';
 
 /// @todo This is some ugly code that needs to be split into several methods
 
@@ -243,7 +241,8 @@ class Delivery {
                                                }
 
                                                if ($normal_mode) {
-                                                       if ($item_id == $item['id'] || $item['id'] == $item['parent']) {
+                                                       // Only add the parent when we don't delete other items.
+                                                       if ($item_id == $item['id'] || (($item['id'] == $item['parent']) && ($cmd != 'drop'))) {
                                                                $item["entry:comment-allow"] = true;
                                                                $item["entry:cid"] = (($top_level) ? $contact['id'] : 0);
                                                                $msgitems[] = $item;