fix: EthAPI: Correctly get parent hash

This commit is contained in:
Aayush
2023-03-03 16:42:57 -05:00
parent 4588523de7
commit 920fdfdf85
2 changed files with 23 additions and 5 deletions
+1 -5
View File
@@ -1763,11 +1763,7 @@ func (e *ethSubscription) stop() {
}
func newEthBlockFromFilecoinTipSet(ctx context.Context, ts *types.TipSet, fullTxInfo bool, cs *store.ChainStore, sa StateAPI) (ethtypes.EthBlock, error) {
parent, err := cs.LoadTipSet(ctx, ts.Parents())
if err != nil {
return ethtypes.EthBlock{}, err
}
parentKeyCid, err := parent.Key().Cid()
parentKeyCid, err := ts.Parents().Cid()
if err != nil {
return ethtypes.EthBlock{}, err
}