From 8321884eef44a124be76a5d7c68ed5b17e483b7d Mon Sep 17 00:00:00 2001
From: Effy Elden <github@effy.is>
Date: Fri, 14 Apr 2017 20:50:00 +1000
Subject: [PATCH] Change usage of gsub to delete, as per Code Climate/Rubocop
 recommendation (#1753)

---
 app/lib/formatter.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/app/lib/formatter.rb b/app/lib/formatter.rb
index 64b1f86d45..a44e5ed3ed 100644
--- a/app/lib/formatter.rb
+++ b/app/lib/formatter.rb
@@ -15,7 +15,7 @@ class Formatter
     html = status.text
     html = encode(html)
     html = simple_format(html, {}, sanitize: false)
-    html = html.gsub(/\n/, '')
+    html = html.delete("\n")
     html = link_urls(html)
     html = link_mentions(html, status.mentions)
     html = link_hashtags(html)
-- 
GitLab