From 44906e2f1bd0d07c93943f74ac6651f3872e20cf Mon Sep 17 00:00:00 2001 From: Booyoun-Kim Date: Fri, 15 Nov 2019 23:41:25 +0900 Subject: [PATCH] Support for kava-2 --- README.md | 2 +- example/kava.js | 6 +++--- package.json | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 89d54f8..c2e5e7d 100644 --- a/README.md +++ b/README.md @@ -73,7 +73,7 @@ iris.setBech32MainPrefix("iaa"); ```js const cosmosjs = require("@cosmostation/cosmosjs"); -const chainId = "kava-testnet-3000"; +const chainId = "kava-2"; const kava = cosmosjs.network(lcdUrl, chainId); kava.setBech32MainPrefix("kava"); ``` diff --git a/example/kava.js b/example/kava.js index 54fec4b..a6c1441 100644 --- a/example/kava.js +++ b/example/kava.js @@ -2,7 +2,7 @@ const cosmosjs = require("../src"); // [WARNING] This mnemonic is just for the demo purpose. DO NOT USE THIS MNEMONIC for your own wallet. const mnemonic = "swear buyer security impulse public stereo peasant correct cross tornado bid discover anchor float venture deal patch property cool wreck eight dwarf december surface"; -const chainId = "kava-testnet-3000"; +const chainId = "kava-2"; const kava = cosmosjs.network("https://lcd-kava.cosmostation.io", chainId); kava.setBech32MainPrefix("kava"); kava.setPath("m/44'/118'/0'/0/0"); @@ -21,8 +21,8 @@ kava.getAccounts(address).then(data => { fee: 5000, gas: 200000, memo: "", - account_number: data.value.account_number, - sequence: data.value.sequence + account_number: data.result.value.account_number, + sequence: data.result.value.sequence }); const signedTx = kava.sign(stdSignMsg, ecpairPriv); diff --git a/package.json b/package.json index d5160cc..e731445 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@cosmostation/cosmosjs", - "version": "0.4.1", + "version": "0.4.2", "description": "A JavasSript Open Source Library for Cosmos Network, IRISnet and Kava", "main": "./src/index.js", "engines": {