quote(value)
public
Quotes the column value to help prevent SQL injection attacks.
Show source
def quote(value)
if value.is_a?(Base)
ActiveSupport::Deprecation.warn(<<~MSG)
Passing an Active Record object to `quote` directly is deprecated
and will be no longer quoted as id value in Rails 6.2.
MSG
value = value.id_for_database
end
_quote(value)
end