Put the title in the body
This commit is contained in:
parent
22c66e1811
commit
b9619ee89a
|
@ -3821,7 +3821,15 @@ class Item extends BaseObject
|
||||||
return $item;
|
return $item;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
$item['body'] = preg_replace("/(.*?\[share.*?\]\s?).*?(\s?\[\/share\]\s?)/ism", '$1' . $shared_item['body'] . '$2', $item['body']);
|
|
||||||
|
if (!empty($shared_item['title'])) {
|
||||||
|
$body = '[h3]' . $shared_item['title'] . "[/h3]\n" . $shared_item['body'];
|
||||||
|
unset($shared_item['title']);
|
||||||
|
} else {
|
||||||
|
$body = $shared_item['body'];
|
||||||
|
}
|
||||||
|
|
||||||
|
$item['body'] = preg_replace("/(.*?\[share.*?\]\s?).*?(\s?\[\/share\]\s?)/ism", '$1' . $body . '$2', $item['body']);
|
||||||
unset($shared_item['body']);
|
unset($shared_item['body']);
|
||||||
|
|
||||||
return array_merge($item, $shared_item);
|
return array_merge($item, $shared_item);
|
||||||
|
|
Loading…
Reference in a new issue