From 9cc5a522df25d7f98e578dc483e0ff067b6c1ded Mon Sep 17 00:00:00 2001 From: Aleksander Machniak <alec@alec.pl> Date: Sat, 30 Aug 2014 06:33:42 -0400 Subject: [PATCH] Fix so rcube_text2html class does not depend on rcmail_string_replacer --- program/lib/Roundcube/rcube_text2html.php | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/program/lib/Roundcube/rcube_text2html.php b/program/lib/Roundcube/rcube_text2html.php index 363f1b2..0afc6d1 100644 --- a/program/lib/Roundcube/rcube_text2html.php +++ b/program/lib/Roundcube/rcube_text2html.php @@ -57,6 +57,8 @@ 'end' => '</div>', // enables links replacement 'links' => true, + // string replacer class + 'replacer' => 'rcube_string_replacer', ); @@ -127,10 +129,8 @@ */ protected function _convert() { - $text = stripslashes($this->text); - // Convert TXT to HTML - $this->html = $this->_converter($text); + $this->html = $this->_converter($this->text); $this->_converted = true; } @@ -143,7 +143,7 @@ { // make links and email-addresses clickable $attribs = array('link_attribs' => array('rel' => 'noreferrer', 'target' => '_blank')); - $replacer = new rcmail_string_replacer($attribs); + $replacer = new $this->config['replacer']($attribs); if ($this->config['flowed']) { $flowed_char = 0x01; -- Gitblit v1.9.1