Skip to content

Commit d47f172

Browse files
author
Aidan Haran
committed
Fix quoting ActiveModel attribute
1 parent d67c2f6 commit d47f172

File tree

1 file changed

+2
-0
lines changed
  • lib/active_record/connection_adapters/sqlserver

1 file changed

+2
-0
lines changed

lib/active_record/connection_adapters/sqlserver/quoting.rb

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,8 @@ def _quote(value)
118118
value.quoted
119119
when String, ActiveSupport::Multibyte::Chars
120120
"#{QUOTED_STRING_PREFIX}#{super}"
121+
when ActiveModel::Attribute
122+
quote(value.value_for_database)
121123
else
122124
super
123125
end

0 commit comments

Comments
 (0)