use Friendica\Protocol\Email;
use dba;
-require_once 'include/html2plain.php';
require_once 'include/items.php';
/// @todo This is some ugly code that needs to be split into several methods
}
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;