PatrickAlphaC / hardhat-nft-fcc

100 stars 139 forks source link

TransactionReceipt.events[1].args bug? #94

Closed eugenekhoo1 closed 1 year ago

eugenekhoo1 commented 1 year ago

I was running test and kept encountering the error Error: invalid BigNumber value (argument="value", value=undefined, code=INVALID_ARGUMENT, version=bignumber/5.7.0), so i figured it might be due to the uint256 requestId being wrong.

Turns out when I console.log(txReceipt.events[1].args)..i get this output:

[
  BigNumber { _hex: '0x01', _isBigNumber: true },
  '0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266',
  requesId: BigNumber { _hex: '0x01', _isBigNumber: true },
  requester: '0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266'
]

Is this a bug where the argument is being misspelled as requesId?? or is it likely due to errors in my code?

PatrickAlphaC commented 1 year ago

Can you:

  1. Make this a discusson on the full repo? https://github.com/smartcontractkit/full-blockchain-solidity-course-js/