about summary refs log tree commit diff
path: root/app/services/process_hashtags_service.rb
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2016-11-05 22:09:51 +0100
committerEugen Rochko <eugen@zeonfederated.com>2016-11-05 22:09:51 +0100
commit7bb28bf7804eadbaeac05e7adb8123a8fb6c5d02 (patch)
tree9bc9bf1fe93f36f169b903d930c69fbaf624ed1d /app/services/process_hashtags_service.rb
parent262adb9791f32162340cec23e3b571655225a3da (diff)
Improve @mention regex
Diffstat (limited to 'app/services/process_hashtags_service.rb')
-rw-r--r--app/services/process_hashtags_service.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/services/process_hashtags_service.rb b/app/services/process_hashtags_service.rb
index 8c68ce989..df30f73ae 100644
--- a/app/services/process_hashtags_service.rb
+++ b/app/services/process_hashtags_service.rb
@@ -4,7 +4,7 @@ class ProcessHashtagsService < BaseService
       tags = status.text.scan(Tag::HASHTAG_RE).map(&:first)
     end
 
-    tags.map(&:downcase).each do |tag|
+    tags.map(&:downcase).uniq.each do |tag|
       status.tags << Tag.where(name: tag).first_or_initialize(name: tag)
     end
   end