mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Provide a more truthful #inspect
This is obviously all very internal, but sometimes you have to look at it... and when you do, it'll save a lot of confusion if it doesn't lie about its identity.
This commit is contained in:
parent
8b96c0b7a3
commit
5d6500535c
1 changed files with 4 additions and 0 deletions
|
@ -26,6 +26,10 @@ module ActiveRecord
|
|||
end
|
||||
end
|
||||
|
||||
def inspect
|
||||
Kernel.instance_method(:inspect).bind(self).call
|
||||
end
|
||||
|
||||
def changed_in_place?(raw_old_value, value)
|
||||
return false if value.nil?
|
||||
raw_new_value = serialize(value)
|
||||
|
|
Loading…
Reference in a new issue