Getting function results with decodeFunctionResult #4981
Replies: 2 comments 1 reply
-
The If you The I am not sure about your situation, but my guess would be you want to provide some getters on your contract (i.e. |
Beta Was this translation helpful? Give feedback.
-
@ricmoo I've managed to figure out
The problem now is I don't know how to get |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
I expect this to produce a result that is returned from the function but instead I get
I tried
decodeFunctionData
and unsurprisingly, i returned "Proposal A". I'm not sure what else I can do. I came across this and I need to do "emit" but I'm not too sure what it is, also it's late so I don't really feel like doing more searching until I rest lol.Also an additional question in this is the difference between
connect
andattach
. The idea behind this contract is that I use a different wallet address to make a vote but I can't tell if it actually works or not. Any help is appreciated, thanksBeta Was this translation helpful? Give feedback.
All reactions