forked from loafle/openapi-generator-original
Ruby Client: nullable for build_from_hash
This commit is contained in:
@@ -22,7 +22,9 @@
|
||||
end
|
||||
elsif !attributes[self.class.attribute_map[key]].nil?
|
||||
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
||||
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
||||
elsif attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
||||
self.send("#{key}=", nil)
|
||||
end
|
||||
end
|
||||
|
||||
self
|
||||
|
||||
Reference in New Issue
Block a user