forked from loafle/openapi-generator-original
[Ruby] Allow Overriding Accept Header (#19106)
* [Ruby] Allow Overriding Accept Header * generate samples
This commit is contained in:
@@ -47,7 +47,7 @@ module Petstore
|
||||
# header parameters
|
||||
header_params = opts[:header_params] || {}
|
||||
# HTTP header 'Accept' (if needed)
|
||||
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
||||
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
||||
# HTTP header 'Content-Type'
|
||||
content_type = @api_client.select_header_content_type(['application/json'])
|
||||
if !content_type.nil?
|
||||
@@ -111,7 +111,7 @@ module Petstore
|
||||
# header parameters
|
||||
header_params = opts[:header_params] || {}
|
||||
# HTTP header 'Accept' (if needed)
|
||||
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
||||
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
||||
# HTTP header 'Content-Type'
|
||||
content_type = @api_client.select_header_content_type(['application/json'])
|
||||
if !content_type.nil?
|
||||
|
||||
Reference in New Issue
Block a user