-
Notifications
You must be signed in to change notification settings - Fork 50
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
FOGL-7375 : Modified to return default value as blank for type:script #953
base: develop
Are you sure you want to change the base?
Conversation
Signed-off-by: nandan <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, this is not what is needed. The default should not be hard coded in the config category class. The filter sets its default to the empty string. Please find out what is adding the extra quotes and fix the problem where it is broken.
Hi Mark, Constructor of CategoryItem itself is adding extra quotes in case of blank values to default. Below are the details from config_category.cpp file at line number# 1267
So it's ok to modify constructor itself ? |
Fixing the constructor would be the right place to fix this. |
…lank value or default config item Signed-off-by: nandan <[email protected]>
It is done |
…es for blank value or default config item" This reverts commit 7615dc0.
Reverted changes as fixing in constructor failing during reconfigure because JSON is having blank value for default instead of quotes
|
Signed-off-by: nandan <[email protected]>
We do not have to do this for any other configuration type, why do we need to do this for scripts? Where did it fail when you fixed the constructor? |
Well if config item is of type script / code then constructor explicitly sets it to quotes rather
If I change m_default = "" then final value in JSON is shown as
So it gets crashed due to Invalid JSON. That's why in case of script/code we should not use escape character sequence So instead of blank it translates to quotes and GUI get quotes as a value of length 2 instead of empty value of length zero. That's why GUI fails here. Let me know further action on this. |
Signed-off-by: nandan [email protected]