Closed m-Peter closed 2 weeks ago
The pull request introduces changes to the To()
method of the DirectCall
struct in models/transaction.go
, specifically adding logic to handle contract deployments by returning nil
for the to
address when the SubType
is DeployCallSubType
. Additionally, it enhances the test case in eth_non_interactive_test.js
by adding assertions to validate the transaction receipt more thoroughly based on the transaction context.
Files | Change Summary |
---|---|
models/transaction.go | Added conditional logic in the To() method of the DirectCall struct to return nil for the to address during contract deployments. |
tests/web3js/eth_non_interactive_test.js | Enhanced assertions in the get block test case to validate the presence of from , contractAddress , and to fields based on transaction index. |
Type()
method in DirectCall
relate to the main PR's changes.RawSignatureValues()
are directly related to modifications in the DirectCall
struct.DirectCall
are relevant to the main PR's modifications.LogsBloom
field may connect to transaction receipt processing.Bugfix
🐰 In the meadow where the code does play,
Anil
forto
, brightens the day.
With tests that hop, and checks that gleam,
We build a world, a coder's dream!
So let us cheer, for changes made,
In the garden of code, our skills displayed! 🌼
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
Description
When the
contractAddress
field is present, theto
field should be absent, as per the JSON-RPC API specification for transaction receipts.For contributor use:
master
branchFiles changed
in the Github PR explorerSummary by CodeRabbit
New Features
to
address is set tonil
for contract creation.Bug Fixes