Bump pg_search from 2.0.1 to 2.3.0
Using pg_search 2.0.1 with Rails 5.2 results in deprecation warnings: DEPRECATION WARNING: Dangerous query method (method whose arguments used as raw SQL) called with non-attribute argument(s): "pg_search_978c2f8941354cf552831b.rank DESC, \"tags\".\"id\" ASC". Non-attribute arguments will be disallowed in Rails 6.0. This method should not be called with user-provided values, such as request parameters or model attributes. Known-safe values can be passed by wrapping them in Arel.sql(). We're not upgrading to the latest pg_search because it only supports ActiveRecord >= 5.2.
This commit is contained in:
@@ -2,7 +2,7 @@ module Searchable
|
||||
extend ActiveSupport::Concern
|
||||
|
||||
included do
|
||||
include PgSearch
|
||||
include PgSearch::Model
|
||||
include SearchCache
|
||||
|
||||
pg_search_scope :pg_search, ->(query) do
|
||||
|
||||
Reference in New Issue
Block a user