thunderclient / thunder-client-support

Thunder Client is a lightweight Rest API Client Extension for VS Code.
https://www.thunderclient.com
Other
3.61k stars 126 forks source link

Special characters get converted incorrectly in cURL import functionality #1472

Closed xiaoxiaobt closed 7 months ago

xiaoxiaobt commented 7 months ago

Describe the bug Whenever there is a special character (for instance, \u0021 i.e. !), the cURL import feature fails to keep the \ in the character, resulting incorrect request body.

To Reproduce

Import

curl "https://example.com" -H 'content-type: application/json' --data-raw $'{"a": "b", "c": "\u0021"}'

Result json body:

{
  "a": "b",
  "c": "u0021"
}

Expected behavior

Expected json body:

{
  "a": "b",
  "c": "\u0021"
}

Platform:

Are you using the free version/paid version/trial:

Free version

rangav commented 7 months ago

This bug is fixed and published to the marketplace, please update to v2.17.5

See all features in this update https://github.com/rangav/thunder-client-support/releases/tag/v2.17.5

Please test and let me know your feedback.