[Bps-public-commit] rt-extension-announce branch, master, updated. 0.06-8-g3bfea66

Wallace Reis wreis at bestpractical.com
Mon Mar 10 15:29:45 EDT 2014


The branch, master has been updated
       via  3bfea66d33310b83e42f9e2b1f4cc327e5c2aa1e (commit)
      from  d69ba3253c59fc4fd1c243e417888cf38b59f977 (commit)

Summary of changes:
 html/Callbacks/RT-Extension-Announce/Elements/PageLayout/BeforeBody | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

- Log -----------------------------------------------------------------
commit 3bfea66d33310b83e42f9e2b1f4cc327e5c2aa1e
Author: Wallace Reis <wreis at bestpractical.com>
Date:   Mon Mar 10 16:27:24 2014 -0300

    Fix body display of messages
    
    The ->Content call defaults to html and we want the plain content
    version instead.

diff --git a/html/Callbacks/RT-Extension-Announce/Elements/PageLayout/BeforeBody b/html/Callbacks/RT-Extension-Announce/Elements/PageLayout/BeforeBody
index dfe14eb..86d8b18 100644
--- a/html/Callbacks/RT-Extension-Announce/Elements/PageLayout/BeforeBody
+++ b/html/Callbacks/RT-Extension-Announce/Elements/PageLayout/BeforeBody
@@ -67,8 +67,7 @@
   }
   $txns->OrderBy( FIELD => 'Created', ORDER => 'DESC' );
   $txns->RowsPerPage(1);
-  my $content_obj = $txns->First->ContentObj;
-  my $content = $content_obj->Content;
+  my $content = $txns->First->Content(Type => 'text/plain');
   if( length $content > $MaxMessageLength ){
     $content = substr($content, 0, $MaxMessageLength);
     # Try to break at a word boundary.

-----------------------------------------------------------------------



More information about the Bps-public-commit mailing list