about summary refs log tree commit diff
path: root/app/lib
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2016-09-10 19:18:17 +0200
committerEugen Rochko <eugen@zeonfederated.com>2016-09-10 19:18:17 +0200
commit3d566279cb84aba6d07eaadebda6c059f2a58657 (patch)
tree39d4bacc44af0eb723499d21a68d6dd967946d35 /app/lib
parent0077fc26df2982720e5fb278af6540a47859386f (diff)
Fix formatter return block
Diffstat (limited to 'app/lib')
-rw-r--r--app/lib/formatter.rb3
1 files changed, 1 insertions, 2 deletions
diff --git a/app/lib/formatter.rb b/app/lib/formatter.rb
index 12b141e7e..ad0f022a7 100644
--- a/app/lib/formatter.rb
+++ b/app/lib/formatter.rb
@@ -37,8 +37,7 @@ class Formatter
       acct    = Account::MENTION_RE.match(match)[1]
       mention = mentions.find { |mention| mention.account.acct.eql?(acct) }
 
-      return match if mention.nil?
-      mention_html(match, mention.account)
+      mention.nil? ? match : mention_html(match, mention.account)
     end
   end