Skip to content

Commit df249ec

Browse files
author
Booyoun
authored
Merge pull request #10 from cosmostation/dev
supporting Akash Network
2 parents 7a5b168 + 3caa348 commit df249ec

2 files changed

Lines changed: 9 additions & 16 deletions

File tree

www/js/bundle.js

Lines changed: 5 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,9 @@
2323
case "secret":
2424
chainId2 = "secret-2";
2525
break;
26+
case "akash":
27+
chainId2 = "akashnet-1";
28+
break;
2629
}
2730

2831
const cosmos = cosmosjs.network(window.lcd, chainId2);
@@ -47,6 +50,8 @@
4750
prefix = "star";
4851
} else if (chainId2.indexOf("secret") != -1) {
4952
prefix = "secret";
53+
} else if (chainId2.indexOf("akash") != -1) {
54+
prefix = "akash";
5055
}
5156

5257
const cosmos = cosmosjs.network(window.lcd, chainId2);
@@ -56,22 +61,6 @@
5661

5762
let signedTx = cosmos.sign(stdSignMsg, ecpairPriv);
5863

59-
// * IRIS exception handling about "irishub/stake/BeginRedelegate" type
60-
// if (signedTx.tx.msg[0].type == "irishub/stake/BeginRedelegate") {
61-
// // The key of "shares" is using to sign for IRIS Redelegate.
62-
// // After signing, you have to replace the "shares" key name to "shares_amount".
63-
// // It is an exception to "irishub/stake/BeginRedelegate".
64-
// var txBodyStr = JSON.stringify(signedTx);
65-
// txBodyStr = txBodyStr.replace("\"shares", "\"shares_amount");
66-
// signedTx = JSON.parse(txBodyStr);
67-
// }
68-
69-
// * Debug
70-
// if (stdSignMsg.json.msgs[0].value.from_address == "[KAVA_ADDRESS]") {
71-
// console.log("signedTx: ", JSON.stringify(signedTx));
72-
// return;
73-
// }
74-
7564
cosmos.broadcast(signedTx).then(response => {
7665
try {
7766
window.opener.postMessage(response, "*");

www/transaction.html

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,7 @@ <h2>Please enter your PIN.</h2>
105105
case "uatom":
106106
case "uband":
107107
case "ukava":
108+
case "uatk":
108109
decimalPlace = 0.000001;
109110
break;
110111
case "iris-atto":
@@ -136,6 +137,9 @@ <h2>Please enter your PIN.</h2>
136137
case "uband":
137138
symbol = "BAND";
138139
break;
140+
case "uatk":
141+
symbol = "ATK";
142+
break;
139143
default:
140144
symbol = denom.toUpperCase();
141145
break;

0 commit comments

Comments
 (0)