Skip to content

Commit fec96ed

Browse files
authored
Merge pull request #139 from centrifuge/update-chainbridge-utils-to-172c1a9
deps: Update chainbridge-utils to 172c1a9
2 parents 4a9e2b4 + 737840f commit fec96ed

File tree

3 files changed

+7
-8
lines changed

3 files changed

+7
-8
lines changed

‎cmd/chainbridge/account.go‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ func handleGenerateCmd(ctx *cli.Context, dHandler *dataHandler) error {
6363
password = []byte(pwdflag)
6464
}
6565

66-
_, err := generateKeypair(keytype, dHandler.datadir, password, uint8(ctx.Uint(config.SubkeyNetworkFlag.Name)))
66+
_, err := generateKeypair(keytype, dHandler.datadir, password, uint16(ctx.Uint(config.SubkeyNetworkFlag.Name)))
6767
if err != nil {
6868
return fmt.Errorf("failed to generate key: %w", err)
6969
}
@@ -159,7 +159,7 @@ func importPrivKey(ctx *cli.Context, keytype, datadir, key string, password []by
159159
if keytype == crypto.Sr25519Type {
160160
// generate sr25519 keys
161161
network := ctx.Uint(config.SubkeyNetworkFlag.Name)
162-
kp, err = sr25519.NewKeypairFromSeed(key, uint8(network))
162+
kp, err = sr25519.NewKeypairFromSeed(key, uint16(network))
163163
if err != nil {
164164
return "", fmt.Errorf("could not generate sr25519 keypair from given string: %w", err)
165165
}
@@ -335,7 +335,7 @@ func getKeyFiles(datadir string) ([]string, error) {
335335
// generateKeypair create a new keypair with the corresponding type and saves it to datadir/keystore/[public key].key
336336
// in json format encrypted using the specified password
337337
// it returns the resulting filepath of the new key
338-
func generateKeypair(keytype, datadir string, password []byte, subNetwork uint8) (string, error) {
338+
func generateKeypair(keytype, datadir string, password []byte, subNetwork uint16) (string, error) {
339339
if password == nil {
340340
password = keystore.GetPassword("Enter password to encrypt keystore file:")
341341
}

‎go.mod‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ require (
1111
github.com/ChainSafe/log15 v1.0.0
1212
github.com/centrifuge/chain-custom-types v0.0.0-20220323235722-1cdf9a3ad7f1
1313
github.com/centrifuge/chainbridge-substrate-events v0.0.0-20220215222726-8c1d3a5cad10
14-
github.com/centrifuge/chainbridge-utils v1.1.1-0.20221001051926-ecac2af5cb68
14+
github.com/centrifuge/chainbridge-utils v1.1.1-0.20230713101127-172c1a918855
1515
github.com/ethereum/go-ethereum v1.10.20
1616
github.com/prometheus/client_golang v1.4.1
1717
github.com/stretchr/testify v1.7.2

‎go.sum‎

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,17 +13,16 @@ github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24
1313
github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8=
1414
github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM=
1515
github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw=
16-
github.com/btcsuite/btcd v0.22.1 h1:CnwP9LM/M9xuRrGSCGeMVs9iv09uMqwsVX7EeIpgV2c=
16+
github.com/btcsuite/btcd v0.22.0-beta h1:LTDpDKUM5EeOFBPM8IXpinEcmZ6FWfNZbE3lfrfdnWo=
1717
github.com/btcsuite/btcd/btcec/v2 v2.2.0 h1:fzn1qaOt32TuLjFlkzYSsBC35Q3KUjT1SwPxiMSCF5k=
1818
github.com/btcsuite/btcd/btcec/v2 v2.2.0/go.mod h1:U7MHm051Al6XmscBQ0BoNydpOTsFAn707034b5nY8zU=
19-
github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1 h1:q0rUy8C/TYNBQS1+CGKw68tLOFYSNEs0TFnxxnS9+4U=
2019
github.com/btcsuite/btcutil v1.0.3-0.20201208143702-a53e38424cce h1:YtWJF7RHm2pYCvA5t0RPmAaLUhREsKuKd+SLhxFbFeQ=
2120
github.com/centrifuge/chain-custom-types v0.0.0-20220323235722-1cdf9a3ad7f1 h1:i72MKnaZ//Nw9T1bJT4PdpfXGfKGckzkHHf97FKyRDI=
2221
github.com/centrifuge/chain-custom-types v0.0.0-20220323235722-1cdf9a3ad7f1/go.mod h1:E+MHt0riACBcD/pPctnW6h6BLNa5BRWF49uz31yFUfQ=
2322
github.com/centrifuge/chainbridge-substrate-events v0.0.0-20220215222726-8c1d3a5cad10 h1:KNpThzo0t8/jpOiY3b2IWSpvksev0XKIR+8mxbNU0zY=
2423
github.com/centrifuge/chainbridge-substrate-events v0.0.0-20220215222726-8c1d3a5cad10/go.mod h1:e5ffvnL405ZXm5n2inQQqDeIWpa6o7FNRwx1QQC8mWo=
25-
github.com/centrifuge/chainbridge-utils v1.1.1-0.20221001051926-ecac2af5cb68 h1:DAm8uyQPQnk8DrV0/BHzzPGiOcK3tL1RRHaX9eqY54U=
26-
github.com/centrifuge/chainbridge-utils v1.1.1-0.20221001051926-ecac2af5cb68/go.mod h1:j5KH69eOiNMy9HCTLj8qABZ4/Lx4SIP29JcPtyA1Neo=
24+
github.com/centrifuge/chainbridge-utils v1.1.1-0.20230713101127-172c1a918855 h1:d1K9UgnQOhjn0nraQ+S0Zkx41OSSjXLSD+b1tB20k6E=
25+
github.com/centrifuge/chainbridge-utils v1.1.1-0.20230713101127-172c1a918855/go.mod h1:/yQYLxYWNl7C/gsBf2pCJRCT6n9K88fdLAse/haCoCI=
2726
github.com/centrifuge/go-substrate-rpc-client/v4 v4.0.17-0.20230713095918-d6e1d43a5270 h1:LMY8PtQg+kMt3fAO2vmfx3kUepcpxj4/pV2FWzOnoc8=
2827
github.com/centrifuge/go-substrate-rpc-client/v4 v4.0.17-0.20230713095918-d6e1d43a5270/go.mod h1:szA5wf9suAIcNg/1S3rGeFITHqrnqH5TC6b+O0SEQ94=
2928
github.com/cespare/cp v0.1.0 h1:SE+dxFebS7Iik5LK0tsi1k9ZCxEaFX4AjQmoyA+1dJk=

0 commit comments

Comments
 (0)