Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix wrong string escape in RichText's attrs #439

Closed
wants to merge 2 commits into from

Conversation

cozitive
Copy link
Contributor

@cozitive cozitive commented Jan 5, 2023

What this PR does / why we need it:
In RichText's attrs, missing backslash before special characters caused JSON parse error. RHT.Marshal() now inserts escape characters when constructing JSON encoding.

Which issue(s) this PR fixes:

Fixes #437

Special notes for your reviewer:

Does this PR introduce a user-facing change?:

NONE

Additional documentation:


Checklist:

  • Added relevant tests or not required
  • Didn't break anything

In RichText's attrs, missing backslash before special characters caused
JSON parse error. RHT.Marshal() now inserts escape characters when
constructing JSON encoding.
@CLAassistant
Copy link

CLAassistant commented Jan 5, 2023

CLA assistant check
All committers have signed the CLA.

@hackerwins hackerwins marked this pull request as draft January 5, 2023 08:17
@cozitive
Copy link
Contributor Author

cozitive commented Jan 5, 2023

This PR will wait for PR #438 to be completed; RichText test should be modified since EscapeString now inserts two backslashes, but the test code is being changed in PR #438.

@hackerwins hackerwins mentioned this pull request Jan 12, 2023
2 tasks
@hackerwins
Copy link
Member

This was merged by #443.

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.

Handle JSON.parse error properly
3 participants