lib/swagalicious/swagger_formatter.rb in swagalicious-0.3.0 vs lib/swagalicious/swagger_formatter.rb in swagalicious-0.3.1
- old
+ new
@@ -123,14 +123,10 @@
schema = target_node[:schema]
return if mime_list.empty? || schema.nil?
mime_list.each do |mime_type|
# TODO upgrade to have content-type specific schema
- body = target_node
- .fetch(:body, {})
- .fetch(mime_type, {})
-
- target_node[:content][mime_type] = { schema: schema }.merge(body)
+ target_node[:content][mime_type] = { schema: schema }
end
end
def upgrade_request_type!(metadata)
# No deprecation here as it seems valid to allow type as a shorthand