Skip to content

Commit

Permalink
wrap Arel.sql to avoid error
Browse files Browse the repository at this point in the history
  • Loading branch information
a5-stable committed Jun 11, 2023
1 parent 0174283 commit 6538d65
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions activerecord/lib/active_record/persistence.rb
Expand Up @@ -122,7 +122,7 @@ def insert(attributes, returning: nil, unique_by: nil, record_timestamps: nil)
# clause entirely.
#
# You can also pass an SQL string if you need more control on the return values
# (for example, <tt>returning: "id, name as new_name"</tt>).
# (for example, <tt>returning: Arel.sql("id, name as new_name")</tt>).
#
# [:unique_by]
# (PostgreSQL and SQLite only) By default rows are considered to be unique
Expand Down Expand Up @@ -212,7 +212,7 @@ def insert!(attributes, returning: nil, record_timestamps: nil)
# clause entirely.
#
# You can also pass an SQL string if you need more control on the return values
# (for example, <tt>returning: "id, name as new_name"</tt>).
# (for example, <tt>returning: Arel.sql("id, name as new_name")</tt>).
#
# [:record_timestamps]
# By default, automatic setting of timestamp columns is controlled by
Expand Down Expand Up @@ -278,7 +278,7 @@ def upsert(attributes, on_duplicate: :update, returning: nil, unique_by: nil, re
# clause entirely.
#
# You can also pass an SQL string if you need more control on the return values
# (for example, <tt>returning: "id, name as new_name"</tt>).
# (for example, <tt>returning: Arel.sql("id, name as new_name")</tt>).
#
# [:unique_by]
# (PostgreSQL and SQLite only) By default rows are considered to be unique
Expand Down

0 comments on commit 6538d65

Please sign in to comment.