@cityofzion/bs-neo-legacy 1.3.0 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -14,6 +14,7 @@ export declare class BSNeoLegacy<BSCustomName extends string = string> implement
|
|
|
14
14
|
network: Network<BSNeoLegacyNetworkId>;
|
|
15
15
|
legacyNetwork: string;
|
|
16
16
|
constructor(blockchainName: BSCustomName, network?: Network<BSNeoLegacyNetworkId>);
|
|
17
|
+
clone(): BSNeoLegacy<BSCustomName>;
|
|
17
18
|
setNetwork(network: Network<BSNeoLegacyNetworkId>): void;
|
|
18
19
|
validateAddress(address: string): boolean;
|
|
19
20
|
validateEncrypted(key: string): boolean;
|
|
@@ -43,6 +43,9 @@ class BSNeoLegacy {
|
|
|
43
43
|
this.bip44DerivationPath = BSNeoLegacyConstants_1.BSNeoLegacyConstants.DEFAULT_BIP44_DERIVATION_PATH;
|
|
44
44
|
this.setNetwork(network);
|
|
45
45
|
}
|
|
46
|
+
clone() {
|
|
47
|
+
return new BSNeoLegacy(this.blockchainName, this.network);
|
|
48
|
+
}
|
|
46
49
|
setNetwork(network) {
|
|
47
50
|
if (!BSNeoLegacyConstants_1.BSNeoLegacyConstants.ALL_NETWORK_IDS.includes(network.id))
|
|
48
51
|
throw new Error('Custom network is not supported');
|
|
@@ -133,7 +136,7 @@ class BSNeoLegacy {
|
|
|
133
136
|
}
|
|
134
137
|
if (!response.tx)
|
|
135
138
|
throw new Error('Failed to send transaction');
|
|
136
|
-
return
|
|
139
|
+
return intents.map(() => response.tx.hash);
|
|
137
140
|
});
|
|
138
141
|
}
|
|
139
142
|
claim(account) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cityofzion/bs-neo-legacy",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.4.0",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"types": "dist/index.d.ts",
|
|
6
6
|
"author": "Coz",
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"@cityofzion/dora-ts": "0.0.11",
|
|
13
13
|
"@cityofzion/neon-js": "4.8.3",
|
|
14
|
-
"@cityofzion/blockchain-service": "1.
|
|
14
|
+
"@cityofzion/blockchain-service": "1.5.0",
|
|
15
15
|
"@cityofzion/bs-asteroid-sdk": "0.9.0"
|
|
16
16
|
},
|
|
17
17
|
"devDependencies": {
|