Skip to content

Commit

Permalink
rubocop complaining
Browse files Browse the repository at this point in the history
  • Loading branch information
dlikhten committed Jun 26, 2019
1 parent 7b36af7 commit afea4d9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/phony_rails.rb
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ def assign_values_for_phony_symbol_options(options)

def cache_original_attribute(current_instance, attribute)
attribute_name = "#{attribute}_original"
current_instance.define_singleton_method("#{attribute_name}=") { |value| instance_variable_set("@#{attribute_name}", value) }
current_instance.define_singleton_method("#{attribute_name}=") { |value| instance_variable_set("@#{attribute_name}", value) }
current_instance.define_singleton_method(attribute_name) { instance_variable_get("@#{attribute_name}") }
current_instance.public_send("#{attribute}_original=", current_instance.public_send(attribute.to_s))
end
Expand Down

0 comments on commit afea4d9

Please sign in to comment.