mirror of
https://github.com/lunaisnotaboy/mastodon.git
synced 2024-11-23 15:24:53 +00:00
Ignore invalid hashtags on remote statuses instead of rejecting them (#9118)
Fixes #9115
This commit is contained in:
parent
82e7988afc
commit
e53cc673e7
|
@ -129,7 +129,7 @@ class ActivityPub::Activity::Create < ActivityPub::Activity
|
||||||
return if tag['name'].blank?
|
return if tag['name'].blank?
|
||||||
|
|
||||||
hashtag = tag['name'].gsub(/\A#/, '').mb_chars.downcase
|
hashtag = tag['name'].gsub(/\A#/, '').mb_chars.downcase
|
||||||
hashtag = Tag.where(name: hashtag).first_or_create(name: hashtag)
|
hashtag = Tag.where(name: hashtag).first_or_create!(name: hashtag)
|
||||||
|
|
||||||
return if @tags.include?(hashtag)
|
return if @tags.include?(hashtag)
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue