Browse Source

Fix ignoring whole status because of one invalid hashtag (#11621)

Fix #11618
pull/4/head
Eugen Rochko 4 years ago
committed by GitHub
parent
commit
dff46b260b
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      app/models/tag.rb

+ 1
- 1
app/models/tag.rb View File

@ -114,7 +114,7 @@ class Tag < ApplicationRecord
class << self
def find_or_create_by_names(name_or_names)
Array(name_or_names).map(&method(:normalize)).uniq { |str| str.mb_chars.downcase.to_s }.map do |normalized_name|
tag = matching_name(normalized_name).first || create(name: normalized_name)
tag = matching_name(normalized_name).first || create!(name: normalized_name)
yield tag if block_given?

Loading…
Cancel
Save