Support JSON serialization options for model objects (#811)

This commit is contained in:
Daniel Azuma authored and GitHub committed 2019-07-29 10:40:39 -07:00
1 parent 05a1367af1
commit 75606c6ca6
2 files changed
+13 -1

No files matched your search

+1 -1
View File
@@ -145,7 +145,7 @@ module Google
def to_json(*a)
representation = self.class.const_get(:Representation)
representation.new(self).to_json(user_options: { skip_undefined: true })
representation.new(self).to_hash(user_options: { skip_undefined: true }).to_json(*a)
end
end
end