这是indexloc提供的服务,不要输入任何密码
Skip to content

Conversation

@alexandermyasnikov
Copy link
Contributor

In v2.22.1, I used the display of examples in the swagger.
In v2.23.0 this was broken by adding the line

op.RequestBody.Content[contentType] = &MediaType{Schema: s}

v2.22.1...v2.23.0#diff-34398007f1f21b0bc55b2fe31480add48b936399f37e1ae49662d9e4dbf33a98R598

Now with the upgrade to v2.23.0+ all my examples are being overwritten and not displayed in swagger.

Made a small fix to make it work for me as before.

Or is there another more correct way to display examples?

@danielgtaylor danielgtaylor requested a review from Copilot January 13, 2025 18:33
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

Copy link
Owner

@danielgtaylor danielgtaylor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is great, thank you!

@codecov
Copy link

codecov bot commented Jan 13, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 92.78%. Comparing base (44aab0b) to head (44eef53).
Report is 9 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #696   +/-   ##
=======================================
  Coverage   92.77%   92.78%           
=======================================
  Files          22       22           
  Lines        4915     4918    +3     
=======================================
+ Hits         4560     4563    +3     
  Misses        308      308           
  Partials       47       47           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@danielgtaylor danielgtaylor merged commit 2861743 into danielgtaylor:main Jan 13, 2025
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants