Skip to content

Conversation

tymcgee
Copy link
Contributor

@tymcgee tymcgee commented Dec 25, 2024

Fixes #150.

  • Switches the example to use resty/v2, which no longer supports resty.DefaultClient
  • Uses a global client instead, which seems to be required in a case like this because resty.New() creates a new transport every time it is called
  • Uses a json responder instead of a text responder to set the content-type header correctly, as referenced in Update resty usage example + Add JsonString responder #150 (comment)

Fixes issue jarcoal#150. Switches the example to use resty/v2, which no longer
supports resty.DefaultClient. It additionally uses a json responder
instead of a text responder to set the content-type header correctly, as
referenced in jarcoal#150 (comment)
Copy link
Collaborator

@maxatome maxatome left a comment

Choose a reason for hiding this comment

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

Thanks, could you fix these small typos, please?

tymcgee and others added 2 commits December 25, 2024 18:57
Co-authored-by: Maxime Soulé <btik-git@scoubidou.com>
Co-authored-by: Maxime Soulé <btik-git@scoubidou.com>
@tymcgee tymcgee requested a review from maxatome December 26, 2024 23:26
@maxatome maxatome merged commit ee13561 into jarcoal:v1 Dec 27, 2024
13 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.

Update resty usage example + Add JsonString responder
2 participants