-
-
Notifications
You must be signed in to change notification settings - Fork 7.5k
fix(cpp-qt-client): #23702 - required members are always present in output of toJsonObject #23703
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
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -65,10 +65,10 @@ QString PFXCategory::asJson() const { | |
|
|
||
| QJsonObject PFXCategory::asJsonObject() const { | ||
| QJsonObject obj; | ||
| if (m_id_isSet) { | ||
| if (true && m_id_isSet) { | ||
| obj.insert(QString("id"), ::test_namespace::toJsonValue(m_id)); | ||
| } | ||
| if (m_name_isSet) { | ||
| if (true && m_name_isSet) { | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. P1: Required Prompt for AI agents
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Category:
title: Pet category
description: A category for a pet
type: object
properties:
id:
type: integer
format: int64
name:
type: string
xml:
name: Categoryand this the check
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @TheZlodziej can we avoid the ``
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks for the feedback! I've saved this as a new learning to improve future reviews. |
||
| obj.insert(QString("name"), ::test_namespace::toJsonValue(m_name)); | ||
| } | ||
| return obj; | ||
|
|
||
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.
P1: Required primitive fields may serialize uninitialized/indeterminate values after this change
Prompt for AI agents