Fix Hash value assignment in JsonSupport#getter_fn

because current version cannot send `false` value.
If given parameter is `false`, current version does not use it.
This commit is contained in:
joker1007 2016-02-25 02:48:02 +09:00
parent b191e60cfc
commit 4b6f5d0a2b
1 changed files with 1 additions and 1 deletions

View File

@ -39,7 +39,7 @@ module Google
ivar_name = "@#{name}".to_sym
lambda do |_|
if respond_to?(:[])
self[name] || instance_variable_get(ivar_name)
self.key?(name) ? self[name] : instance_variable_get(ivar_name)
else
instance_variable_get(ivar_name)
end