This commit is contained in:
Jim McDonald 2017-06-20 15:29:08 +00:00 committed by GitHub
commit de9b25a755

View file

@ -167,11 +167,11 @@ func (ec *Client) TransactionByHash(ctx context.Context, hash common.Hash) (tx *
} else if _, r, _ := tx.RawSignatureValues(); r == nil {
return nil, false, fmt.Errorf("server returned transaction without signature")
}
var block struct{ BlockHash *common.Hash }
var block struct{ BlockNumber *string }
if err := json.Unmarshal(raw, &block); err != nil {
return nil, false, err
}
return tx, block.BlockHash == nil, nil
return tx, block.BlockNumber == nil, nil
}
// TransactionCount returns the total number of transactions in the given block.