infinum/dox

Content-Type header in request sample section is different than the actual request Content-Type header

Opened this issue · 0 comments

The Content-Type header in request sample section does not match actual content type in the request:
image

The cause of this issue is in the

headers.find { |key, _| key == 'Accept' }&.last || 'any'

because it reads Accept header instead of Content-Type header.

When the line is changed to this:

headers.find { |key, _| key == 'Content-Type' }&.last || 'any'

then the out looks correct:
image