@rabbitio/ui-kit 1.0.0-beta.22 → 1.0.0-beta.23
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/index.cjs +4 -5
- package/dist/index.cjs.map +1 -1
- package/dist/index.modern.js +6 -0
- package/dist/index.modern.js.map +1 -1
- package/dist/index.module.js +4 -5
- package/dist/index.module.js.map +1 -1
- package/dist/index.umd.js +4 -5
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/swaps-lib/external-apis/swapProvider.js +20 -1
- package/src/swaps-lib/external-apis/swapspaceSwapProvider.js +32 -0
- package/src/swaps-lib/services/publicSwapService.js +25 -5
package/dist/index.modern.js
CHANGED
|
@@ -2865,6 +2865,12 @@ class SwapspaceSwapProvider extends SwapProvider {
|
|
|
2865
2865
|
if (!fromCoinSwapspaceDetails || !toCoinSwapspaceDetails) {
|
|
2866
2866
|
throw new Error("Failed to find swapspace coin details for: " + fromCoin.ticker + " -> " + toCoin.ticker);
|
|
2867
2867
|
}
|
|
2868
|
+
if (!fromCoinSwapspaceDetails.deposit || !toCoinSwapspaceDetails.withdrawal) {
|
|
2869
|
+
return {
|
|
2870
|
+
result: false,
|
|
2871
|
+
reason: SwapProvider.NO_SWAPS_REASONS.NOT_SUPPORTED
|
|
2872
|
+
};
|
|
2873
|
+
}
|
|
2868
2874
|
/* Here we use not documented parameter 'estimated=false'. This parameter controls whether we want to use
|
|
2869
2875
|
* cached rate values stored in swapspace cache. Their support says they store at most for 30 sec.
|
|
2870
2876
|
* But we are better off using the most actual rates.
|