Fix Person.find_by_substring with frozen strings
This commit is contained in:
parent
723be461cf
commit
9556790480
1 changed files with 1 additions and 1 deletions
|
|
@ -104,7 +104,7 @@ class Person < ApplicationRecord
|
|||
# @param [String] search substring
|
||||
# @return [Person::ActiveRecord_Relation]
|
||||
scope :find_by_substring, ->(search_str) {
|
||||
search_str.strip!
|
||||
search_str = search_str.strip
|
||||
if search_str.blank? || search_str.size < 2
|
||||
none
|
||||
else
|
||||
|
|
|
|||
Loading…
Reference in a new issue