logo

mastofe

My custom branche(s) on git.pleroma.social/pleroma/mastofe
commit: 950312bada605e9df832aa05fe5010450af9a567
parent: 2cb3dc5e5a1320efda89b258048e7bc3542a5744
Author: Eugen Rochko <eugen@zeonfederated.com>
Date:   Sat, 26 Nov 2016 15:24:14 +0100

Fix #278 - Use mb_chars.downcase on hashtags

Diffstat:

Mapp/services/process_hashtags_service.rb2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/app/services/process_hashtags_service.rb b/app/services/process_hashtags_service.rb @@ -4,7 +4,7 @@ class ProcessHashtagsService < BaseService def call(status, tags = []) tags = status.text.scan(Tag::HASHTAG_RE).map(&:first) if status.local? - tags.map(&:downcase).uniq.each do |tag| + tags.map { |str| str.mb_chars.downcase }.uniq.each do |tag| status.tags << Tag.where(name: tag).first_or_initialize(name: tag) end end