@cryptorubic/core 0.12.5 → 0.12.6
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/package.json
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare const wrappedAddress: Partial<Record<
|
|
1
|
+
import { BlockchainName } from './blockchain-name';
|
|
2
|
+
export declare const wrappedAddress: Partial<Record<BlockchainName, string>>;
|
|
@@ -62,6 +62,7 @@ exports.wrappedAddress = {
|
|
|
62
62
|
[blockchain_name_1.BLOCKCHAIN_NAME.UNICHAIN]: '0x4200000000000000000000000000000000000006',
|
|
63
63
|
[blockchain_name_1.BLOCKCHAIN_NAME.MORPH]: '0x5300000000000000000000000000000000000011',
|
|
64
64
|
[blockchain_name_1.BLOCKCHAIN_NAME.HEMI]: '0x4200000000000000000000000000000000000006',
|
|
65
|
+
[blockchain_name_1.BLOCKCHAIN_NAME.SOLANA]: 'So11111111111111111111111111111111111111112',
|
|
65
66
|
// Testnet
|
|
66
67
|
[blockchain_name_1.BLOCKCHAIN_NAME.GOERLI]: '0xb4fbf271143f4fbf7b91a5ded31805e42b2208d6',
|
|
67
68
|
[blockchain_name_1.BLOCKCHAIN_NAME.SCROLL_SEPOLIA]: '0x5300000000000000000000000000000000000004',
|
package/src/lib/tokens/token.js
CHANGED
|
@@ -18,14 +18,11 @@ class Token {
|
|
|
18
18
|
return nativeAddress.toLowerCase() === this.address.toLowerCase();
|
|
19
19
|
}
|
|
20
20
|
get isWrapped() {
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
return false;
|
|
25
|
-
}
|
|
26
|
-
return address.toLowerCase() === this.address.toLowerCase();
|
|
21
|
+
const address = wrapped_addresses_1.wrappedAddress[this.blockchain];
|
|
22
|
+
if (!address) {
|
|
23
|
+
return false;
|
|
27
24
|
}
|
|
28
|
-
return
|
|
25
|
+
return address.toLowerCase() === this.address.toLowerCase();
|
|
29
26
|
}
|
|
30
27
|
get asStruct() {
|
|
31
28
|
return {
|