aboutsummaryrefslogtreecommitdiff
path: root/plugin/evm/tx.go
diff options
context:
space:
mode:
authorAaron Buchwald <[email protected]>2020-11-25 11:20:36 -0500
committerAaron Buchwald <[email protected]>2020-11-25 11:25:20 -0500
commit61479754d935e36993f7144d70d7c518cdb26a36 (patch)
treece38ae6325561029628e09929615e141e7f3b144 /plugin/evm/tx.go
parent44c27ae8f05bb7f1076d9159d4106afd41e2e010 (diff)
Add avax API client and upgrade to avalanchego v1.0.5-client
Diffstat (limited to 'plugin/evm/tx.go')
-rw-r--r--plugin/evm/tx.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/plugin/evm/tx.go b/plugin/evm/tx.go
index 82d4c10..1c0ce48 100644
--- a/plugin/evm/tx.go
+++ b/plugin/evm/tx.go
@@ -89,8 +89,8 @@ type Tx struct {
// (*secp256k1fx.Credential)
// Sign this transaction with the provided signers
-func (tx *Tx) Sign(c codec.Codec, signers [][]*crypto.PrivateKeySECP256K1R) error {
- unsignedBytes, err := c.Marshal(&tx.UnsignedTx)
+func (tx *Tx) Sign(c codec.Manager, signers [][]*crypto.PrivateKeySECP256K1R) error {
+ unsignedBytes, err := c.Marshal(codecVersion, &tx.UnsignedTx)
if err != nil {
return fmt.Errorf("couldn't marshal UnsignedTx: %w", err)
}
@@ -111,7 +111,7 @@ func (tx *Tx) Sign(c codec.Codec, signers [][]*crypto.PrivateKeySECP256K1R) erro
tx.Creds = append(tx.Creds, cred) // Attach credential
}
- signedBytes, err := c.Marshal(tx)
+ signedBytes, err := c.Marshal(codecVersion, tx)
if err != nil {
return fmt.Errorf("couldn't marshal Tx: %w", err)
}