mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
add frozen string literal comment
This commit is contained in:
parent
2396f79fec
commit
b2999d631f
1 changed files with 3 additions and 1 deletions
|
@ -1,3 +1,5 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
require "active_support/core_ext/hash/keys"
|
||||
|
||||
module ActiveModel
|
||||
|
@ -42,7 +44,7 @@ module ActiveModel
|
|||
end
|
||||
|
||||
def _assign_attribute(k, v)
|
||||
setter = "#{k}=".freeze
|
||||
setter = :"#{k}="
|
||||
if respond_to?(setter)
|
||||
public_send(setter, v)
|
||||
else
|
||||
|
|
Loading…
Reference in a new issue