Fixed IsContract method to use the contractCreation flag
This commit is contained in:
parent
56a58ad70d
commit
3c3431d111
@ -1,7 +1,6 @@
|
|||||||
package ethchain
|
package ethchain
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"bytes"
|
|
||||||
"github.com/ethereum/eth-go/ethutil"
|
"github.com/ethereum/eth-go/ethutil"
|
||||||
"github.com/obscuren/secp256k1-go"
|
"github.com/obscuren/secp256k1-go"
|
||||||
"math/big"
|
"math/big"
|
||||||
@ -62,7 +61,7 @@ func (tx *Transaction) Hash() []byte {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (tx *Transaction) IsContract() bool {
|
func (tx *Transaction) IsContract() bool {
|
||||||
return bytes.Compare(tx.Recipient, ContractAddr) == 0
|
return tx.contractCreation
|
||||||
}
|
}
|
||||||
|
|
||||||
func (tx *Transaction) Signature(key []byte) []byte {
|
func (tx *Transaction) Signature(key []byte) []byte {
|
||||||
|
Loading…
Reference in New Issue
Block a user