@cityofzion/bs-ethereum 2.13.1 → 2.13.2
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.
package/dist/BSEthereum.js
CHANGED
|
@@ -229,7 +229,7 @@ _BSEthereum_instances = new WeakSet(), _BSEthereum_buildTransferParams = functio
|
|
|
229
229
|
let transactionParams = {
|
|
230
230
|
type: 2,
|
|
231
231
|
};
|
|
232
|
-
const isNative = this.tokenService.predicateByHash(this.feeToken
|
|
232
|
+
const isNative = this.tokenService.predicateByHash(this.feeToken, intent.tokenHash);
|
|
233
233
|
if (isNative) {
|
|
234
234
|
transactionParams.to = intent.receiverAddress;
|
|
235
235
|
transactionParams.value = amount;
|
|
@@ -112,7 +112,7 @@ class MoralisBDSEthereum extends DoraBDSEthereum_1.DoraBDSEthereum {
|
|
|
112
112
|
return _super.getTokenInfo.call(this, hash);
|
|
113
113
|
}
|
|
114
114
|
const nativeAsset = BSEthereumHelper_1.BSEthereumHelper.getNativeAsset(this._network);
|
|
115
|
-
if (this._tokenService.predicateByHash(nativeAsset
|
|
115
|
+
if (this._tokenService.predicateByHash(nativeAsset, hash))
|
|
116
116
|
return nativeAsset;
|
|
117
117
|
if (this._tokenCache.has(hash)) {
|
|
118
118
|
return this._tokenCache.get(hash);
|
|
@@ -72,7 +72,7 @@ class RpcBDSEthereum {
|
|
|
72
72
|
getTokenInfo(hash) {
|
|
73
73
|
return __awaiter(this, void 0, void 0, function* () {
|
|
74
74
|
const nativeAsset = BSEthereumHelper_1.BSEthereumHelper.getNativeAsset(this._network);
|
|
75
|
-
if (this._tokenService.predicateByHash(nativeAsset
|
|
75
|
+
if (this._tokenService.predicateByHash(nativeAsset, hash))
|
|
76
76
|
return nativeAsset;
|
|
77
77
|
if (this._tokenCache.has(hash)) {
|
|
78
78
|
return this._tokenCache.get(hash);
|
|
@@ -79,7 +79,7 @@ class MoralisEDSEthereum extends blockchain_service_1.CryptoCompareEDS {
|
|
|
79
79
|
});
|
|
80
80
|
data.forEach(item => {
|
|
81
81
|
let token;
|
|
82
|
-
if (wrappedNativeToken && __classPrivateFieldGet(this, _MoralisEDSEthereum_tokenService, "f").predicateByHash(wrappedNativeToken
|
|
82
|
+
if (wrappedNativeToken && __classPrivateFieldGet(this, _MoralisEDSEthereum_tokenService, "f").predicateByHash(wrappedNativeToken, item.tokenAddress)) {
|
|
83
83
|
token = nativeToken;
|
|
84
84
|
}
|
|
85
85
|
else {
|
|
@@ -107,7 +107,7 @@ class MoralisEDSEthereum extends blockchain_service_1.CryptoCompareEDS {
|
|
|
107
107
|
throw new Error('Exchange is not supported on this network');
|
|
108
108
|
const nativeToken = BSEthereumHelper_1.BSEthereumHelper.getNativeAsset(__classPrivateFieldGet(this, _MoralisEDSEthereum_network, "f"));
|
|
109
109
|
let token;
|
|
110
|
-
if (__classPrivateFieldGet(this, _MoralisEDSEthereum_tokenService, "f").predicateByHash(nativeToken
|
|
110
|
+
if (__classPrivateFieldGet(this, _MoralisEDSEthereum_tokenService, "f").predicateByHash(nativeToken, params.token)) {
|
|
111
111
|
token = yield __classPrivateFieldGet(this, _MoralisEDSEthereum_instances, "m", _MoralisEDSEthereum_getWrappedNativeToken).call(this);
|
|
112
112
|
}
|
|
113
113
|
else {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cityofzion/bs-ethereum",
|
|
3
|
-
"version": "2.13.
|
|
3
|
+
"version": "2.13.2",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"types": "dist/index.d.ts",
|
|
6
6
|
"repository": "https://github.com/CityOfZion/blockchain-services",
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
"@ethersproject/properties": "~5.7.0",
|
|
23
23
|
"@cityofzion/dora-ts": "0.5.1",
|
|
24
24
|
"date-fns": "~4.1.0",
|
|
25
|
-
"@cityofzion/blockchain-service": "1.21.
|
|
25
|
+
"@cityofzion/blockchain-service": "1.21.1"
|
|
26
26
|
},
|
|
27
27
|
"devDependencies": {
|
|
28
28
|
"@ledgerhq/hw-transport-node-hid": "~6.28.5",
|