simple patch to avoid lj-cut for short posts

xfyre - February 10, 2008 - 10:36
Project:LiveJournal CrossPoster
Version:5.x-1.2
Component:Code
Category:feature request
Priority:normal
Assigned:Unassigned
Status:active
Description

--- ljxp.module.orig 2008-02-10 13:29:41.517454604 +0300
+++ ljxp.module 2008-02-10 13:26:16.344560865 +0300
@@ -413,7 +413,9 @@
case 'lj-cut':
$body = str_replace($node->teaser, '', $node->body);
$cut = $ljxp->cut_text ? ('cut_text . '">') : '';
- $message['event'] = check_markup($node->teaser, $node->format, TRUE) . $cut . check_markup($body, $node->format, true);
+ $message['event'] = $body ?
+ check_markup($node->teaser, $node->format, TRUE) . $cut . check_markup($body, $node->format, true) :
+ check_markup($node->teaser, $node->format, TRUE);
break;
case 'full post':
$message['event'] = check_markup($node->body, $node->format, TRUE);

 
 

Drupal is a registered trademark of Dries Buytaert.