Skip to content
Snippets Groups Projects
Commit fa7a0255 authored by Jared Hancock's avatar Jared Hancock
Browse files

Strip leading and trailing WS from text mails

parent 924d5616
Branches
Tags
No related merge requests found
......@@ -379,9 +379,7 @@ class Format {
}
function stripEmptyLines($string) {
//return preg_replace("/(^[\r\n]*|[\r\n]+)[\s\t]*[\r\n]+/", "\n", $string);
//return preg_replace('/\s\s+/',"\n",$string); //Too strict??
return preg_replace("/\n{3,}/", "\n\n", $string);
return preg_replace("/\n{3,}/", "\n\n", trim($string));
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment