mirror of
https://github.com/basicswap/basicswap.git
synced 2025-11-05 18:38:09 +01:00
ui: Don't reset the swap type if it's a valid option.
This commit is contained in:
@@ -329,7 +329,9 @@ const SwapTypeManager = {
|
|||||||
} else {
|
} else {
|
||||||
swapTypeElement.disabled = false;
|
swapTypeElement.disabled = false;
|
||||||
swapTypeElement.classList.remove('select-disabled');
|
swapTypeElement.classList.remove('select-disabled');
|
||||||
swapTypeElement.value = 'xmr_swap';
|
if (['xmr_swap', 'seller_first'].includes(swapTypeElement.value) == false) {
|
||||||
|
swapTypeElement.value = 'xmr_swap';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
let swapTypeHidden = DOM.get('swap_type_hidden');
|
let swapTypeHidden = DOM.get('swap_type_hidden');
|
||||||
@@ -353,10 +355,6 @@ const SwapTypeManager = {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
function set_swap_type_enabled(coinFrom, coinTo, swapTypeElement) {
|
|
||||||
SwapTypeManager.setSwapTypeEnabled(coinFrom, coinTo, swapTypeElement);
|
|
||||||
}
|
|
||||||
|
|
||||||
const UIEnhancer = {
|
const UIEnhancer = {
|
||||||
handleErrorHighlighting: () => {
|
handleErrorHighlighting: () => {
|
||||||
const errMsgs = document.querySelectorAll('p.error_msg');
|
const errMsgs = document.querySelectorAll('p.error_msg');
|
||||||
|
|||||||
Reference in New Issue
Block a user