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

Json file not properly formatted in case a string contains a single double quote #39

Closed
andre-f-m opened this issue Jun 22, 2020 · 4 comments
Labels

Comments

@andre-f-m
Copy link

In Quick.Config.JSON when a string contains a single double quote, the resultant file is not formatted properly

@andre-f-m
Copy link
Author

In file JSON Utils, you need to swap the order of two lines at the end. It worked for me, but please review.

From:
isEscape := (c = '') and not isEscape;
if not isEscape and (c = '"') then isIntoString := not isIntoString;

to:
if not isEscape and (c = '"') then isIntoString := not isIntoString;
isEscape := (c = '') and not isEscape;

@exilon
Copy link
Owner

exilon commented Jun 27, 2020

When a string contains a single double quote? Then it's not a good json object...Could you explain please?

@andre-f-m
Copy link
Author

If you have a string property (e.g. SQL) and store in this string for example:
select * from actor where name like '% ABC" %'
then after you saving, you will notice that the config file is not properly formatted. Making the change I mentioned it worked for me.

@exilon exilon added the bug label Jun 27, 2020
exilon added a commit that referenced this issue Jun 27, 2020
@exilon
Copy link
Owner

exilon commented Jun 27, 2020

You're right. I've applied your changes. Thanks.

@exilon exilon closed this as completed Jun 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants