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

Accept parameter value null in neo-invoke.json interactive mode #161

Open
mialbu opened this issue Apr 4, 2023 · 1 comment
Open

Accept parameter value null in neo-invoke.json interactive mode #161

mialbu opened this issue Apr 4, 2023 · 1 comment

Comments

@mialbu
Copy link

mialbu commented Apr 4, 2023

When trying to invoke the transfer method of the NeoToken, it is not intuitive what to do when one does not want to pass any data (i.e., the 4th parameter). I tried with simply null but that disregards that parameter and tries to invoke a method transfer with only 3 parameters (which doesn't exist and thus fails).

image

Suggestion: Allow passing a value in interactive mode which would translate to the opcode PUSHNULL in the invoke script. For example, simply null like mentioned above.

@mialbu
Copy link
Author

mialbu commented Apr 4, 2023

New observation: If you write null in the interactive mode, nothing is added to the actual .json file. If I add null manually in the JSON editor mode, it converts to the PUSHNULL opcode in the invoke script as expected.

@mialbu mialbu changed the title Accept parameter value null in neo-invoke scripts Accept parameter value null in neo-invoke.json interactive mode Apr 4, 2023
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

No branches or pull requests

1 participant