public function convertLineBreaks($string) {
        if ($this->getConfig('lineBreaks')) {

            // Don't use nl2br() since it leaves a \n
            if ($this->getConfig('xhtmlOutput')) {
                $string = str_replace("\n", '<br/>', $string);
            } else {
                $string = str_replace("\n", '<br>', $string);
            }
        }

        return $string;
    }