Skip to content
Snippets Groups Projects
Commit 9e2cc9ef authored by Bernardo Cardoso's avatar Bernardo Cardoso
Browse files

Update app name

parent 89bc0449
No related branches found
No related tags found
No related merge requests found
const { newElixxirApp } = require('@zondax/ledger-substrate'); const { newXXNetworkApp } = require('@zondax/ledger-substrate');
const TransportNodeHid = require("@ledgerhq/hw-transport-node-hid"); const TransportNodeHid = require("@ledgerhq/hw-transport-node-hid");
const { ApiPromise, WsProvider } = require('@polkadot/api'); const { ApiPromise, WsProvider } = require('@polkadot/api');
require('dotenv').config(); require('dotenv').config();
...@@ -7,7 +7,7 @@ const LEDGER = '6WA132Y5Ycgz3cXUt6a6rEhcJ4imhxXAij7x5Gefha5wu83g'; ...@@ -7,7 +7,7 @@ const LEDGER = '6WA132Y5Ycgz3cXUt6a6rEhcJ4imhxXAij7x5Gefha5wu83g';
const ALICE = '6a6XHUGV5mu33rX1vn3iivxxUR4hwoUapsuECGyHpPzfaNtt'; const ALICE = '6a6XHUGV5mu33rX1vn3iivxxUR4hwoUapsuECGyHpPzfaNtt';
/** /**
* Connect to an xx network node using websocket * Connect to a xx network node using websocket
* @return {Promise} chain api * @return {Promise} chain api
*/ */
async function connect() { async function connect() {
...@@ -40,12 +40,12 @@ async function sendAndWait(extrinsic, final) { ...@@ -40,12 +40,12 @@ async function sendAndWait(extrinsic, final) {
async function main () { async function main () {
const transport = await TransportNodeHid.default.create(); const transport = await TransportNodeHid.default.create();
const app = newElixxirApp(transport); const app = newXXNetworkApp(transport);
// Connect to the node // Connect to the node
const api = await connect(); const api = await connect();
// Create a extrinsic, transferring 10 units to Alice (with 9 decimals) // Create an extrinsic, transferring 10 units to Alice (with 9 decimals)
const transfer = api.tx.balances.transfer(ALICE, 10_000000000); const transfer = api.tx.balances.transfer(ALICE, 10_000000000);
// Get the current nonce for the sending account // Get the current nonce for the sending account
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
"dependencies": { "dependencies": {
"@ledgerhq/hw-transport-node-hid": "^6.24.1", "@ledgerhq/hw-transport-node-hid": "^6.24.1",
"@polkadot/api": "^7.15.1", "@polkadot/api": "^7.15.1",
"@zondax/ledger-substrate": "^0.24.0", "@zondax/ledger-substrate": "^0.25.0",
"dotenv": "^16.0.0" "dotenv": "^16.0.0"
} }
} }
...@@ -440,10 +440,10 @@ ...@@ -440,10 +440,10 @@
dependencies: dependencies:
"@types/node" "*" "@types/node" "*"
"@zondax/ledger-substrate@^0.24.0": "@zondax/ledger-substrate@^0.25.0":
version "0.24.0" version "0.25.0"
resolved "https://registry.yarnpkg.com/@zondax/ledger-substrate/-/ledger-substrate-0.24.0.tgz#af6d22e36c2daef93acc21fa047e3c4d16ebe111" resolved "https://registry.yarnpkg.com/@zondax/ledger-substrate/-/ledger-substrate-0.25.0.tgz#8e7ec330e5ac5e16c244df69d0c456a358ed9e32"
integrity sha512-/Rax9ETDiFSz73vM5b8y06hMXatHqE28uK4hWbhrC31i3rxr7VgHHtMhlcNZtI+WeanpQN9jcyUDTKySuHILCQ== integrity sha512-A3fmBVmOry2rGn9zrgcEeT6EL3+8YaeQBI7HpRaPcoURTJJ2AQDHRaOGWr2VuHrUD0z/lVbdrRC66/bMwGf+IA==
dependencies: dependencies:
"@babel/runtime" "^7.14.8" "@babel/runtime" "^7.14.8"
"@ledgerhq/hw-transport" "^6.2.0" "@ledgerhq/hw-transport" "^6.2.0"
...@@ -501,9 +501,9 @@ bindings@^1.3.0, bindings@^1.5.0: ...@@ -501,9 +501,9 @@ bindings@^1.3.0, bindings@^1.5.0:
dependencies: dependencies:
file-uri-to-path "1.0.0" file-uri-to-path "1.0.0"
"bip32-ed25519@https://github.com/Zondax/bip32-ed25519": "bip32-ed25519@git+https://github.com/Zondax/bip32-ed25519.git":
version "0.0.4" version "0.0.4"
resolved "https://github.com/Zondax/bip32-ed25519#0949df01b5c93885339bc28116690292088f6134" resolved "git+https://github.com/Zondax/bip32-ed25519.git#0949df01b5c93885339bc28116690292088f6134"
dependencies: dependencies:
bn.js "^5.1.1" bn.js "^5.1.1"
elliptic "^6.4.1" elliptic "^6.4.1"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment