aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--app/models/incoming_message.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/app/models/incoming_message.rb b/app/models/incoming_message.rb
index dd729d761..7ede7559e 100644
--- a/app/models/incoming_message.rb
+++ b/app/models/incoming_message.rb
@@ -17,7 +17,7 @@
# Copyright (c) 2007 UK Citizens Online Democracy. All rights reserved.
# Email: francis@mysociety.org; WWW: http://www.mysociety.org/
#
-# $Id: incoming_message.rb,v 1.97 2008-05-12 01:38:18 francis Exp $
+# $Id: incoming_message.rb,v 1.98 2008-05-12 16:53:03 francis Exp $
# TODO
# Move some of the (e.g. quoting) functions here into rblib, as they feel
@@ -525,6 +525,7 @@ class IncomingMessage < ActiveRecord::Base
text.strip!
text = text.gsub(/\n/, '<br>')
+ text = text.gsub(/(?:<br>\s*){2,}/, '<br><br>') # remove excess linebreaks that unnecessarily space it out
return text
end