Skip to content

Commit

Permalink
fix: set sdk context before account creation
Browse files Browse the repository at this point in the history
  • Loading branch information
debendraoli committed Nov 19, 2024
1 parent 7c6f42d commit 6f0646c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions relayer/chains/wasm/keys.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,12 @@ func (p *Provider) RestoreKeystore(ctx context.Context) error {
}

func (p *Provider) NewKeystore(passphrase string) (string, error) {
done := p.SetSDKContext()
defer done()
armor, addr, err := p.client.CreateAccount(p.NID(), passphrase)
if err != nil {
return "", err
}
done := p.SetSDKContext()
defer done()
encryptedArmor, err := p.kms.Encrypt(context.Background(), []byte(armor))
if err != nil {
return "", err
Expand Down

0 comments on commit 6f0646c

Please sign in to comment.