Filter superfluous spaces in display subjects
authorMichael M Slusarz <slusarz@curecanti.org>
Thu, 18 Mar 2010 05:53:44 +0000 (23:53 -0600)
committerMichael M Slusarz <slusarz@curecanti.org>
Thu, 18 Mar 2010 17:33:33 +0000 (11:33 -0600)
imp/lib/Ui/Message.php

index 8c61abd..d7e3d8e 100644 (file)
@@ -621,7 +621,7 @@ class IMP_Ui_Message
      */
     public function getDisplaySubject($subject)
     {
-        return Horde_Text_Filter::filter(IMP::filterText($subject), 'text2html', array(
+        return Horde_Text_Filter::filter(preg_replace("/\b\s+\b/", ' ', IMP::filterText($subject)), 'text2html', array(
             // See Ticket #8836
             'noprefetch' => ($GLOBALS['browser']->isBrowser('mozilla') && !$GLOBALS['browser']->usingSSLConnection()),
             'parselevel' => Horde_Text_Filter_Text2html::MICRO