@manifoldxyz/marketplace-sdk 3.0.2 → 3.0.3
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.
|
@@ -640,8 +640,9 @@ class MarketplaceListing {
|
|
|
640
640
|
}
|
|
641
641
|
getCurrency() {
|
|
642
642
|
return __awaiter(this, void 0, void 0, function* () {
|
|
643
|
+
const network = window.ManifoldEthereumProvider.network();
|
|
643
644
|
if (!this.listing.erc20)
|
|
644
|
-
return 'ETH';
|
|
645
|
+
return network == frontend_provider_types_1.EthereumNetwork.OPTIMISM ? 'OETH' : 'ETH';
|
|
645
646
|
return this._callWeb3WithServerFallback(this._getERC20Contract(false, false), this._getERC20Contract(false, false, true), 'symbol', []);
|
|
646
647
|
});
|
|
647
648
|
}
|
package/package.json
CHANGED
|
@@ -645,7 +645,8 @@ class MarketplaceListing {
|
|
|
645
645
|
}
|
|
646
646
|
|
|
647
647
|
public async getCurrency(): Promise<string> {
|
|
648
|
-
|
|
648
|
+
const network = window.ManifoldEthereumProvider.network()
|
|
649
|
+
if(!this.listing!.erc20) return network == EthereumNetwork.OPTIMISM ? 'OETH' : 'ETH'
|
|
649
650
|
return this._callWeb3WithServerFallback(
|
|
650
651
|
this._getERC20Contract(false, false), this._getERC20Contract(false, false, true)!, 'symbol', []
|
|
651
652
|
)
|