-
Notifications
You must be signed in to change notification settings - Fork 205
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
Rename argument
field to payload
in the command/create
request
#4192
Conversation
[JSON API - Experimental] Rename ``argument`` field to ``payload`` in the ``command/create`` request. See #4189. CHANGELOG_END
@@ -154,12 +154,12 @@ class Ledger { | |||
/** | |||
* Create a contract for a given template. | |||
*/ | |||
async create<T extends object, K>(template: Template<T, K>, argument: T): Promise<CreateEvent<T, K>> { | |||
const payload = { | |||
async create<T extends object, K>(template: Template<T, K>, contractPayload: T): Promise<CreateEvent<T, K>> { |
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.
async create<T extends object, K>(template: Template<T, K>, contractPayload: T): Promise<CreateEvent<T, K>> { | |
async create<T extends object, K>(template: Template<T, K>, payload: T): Promise<CreateEvent<T, K>> { |
Seems more in the spirit of the change, no?
templateId: template.templateId, | ||
argument, | ||
payload: contractPayload, |
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.
payload: contractPayload, | |
payload, |
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.
I guess, it is just in a few other places, @hurryabit refers to the entire command as a payload.
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.
Fair, well, whatever you think is best.
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.
I like this change very much. Thanks a lot.
Rename
argument
field topayload
in thecommand/create
request.Closes: #4189
Pull Request Checklist
CHANGELOG_BEGIN
andCHANGELOG_END
tagsNOTE: CI is not automatically run on non-members pull-requests for security
reasons. The reviewer will have to comment with
/AzurePipelines run
totrigger the build.