Skip to content

Commit

Permalink
exmo: update deposit/withdraw flag
Browse files Browse the repository at this point in the history
  • Loading branch information
sc0Vu committed Jan 14, 2022
1 parent 1ac9d57 commit 7f4431f
Showing 1 changed file with 18 additions and 2 deletions.
20 changes: 18 additions & 2 deletions js/exmo.js
Original file line number Diff line number Diff line change
Expand Up @@ -344,6 +344,8 @@ module.exports = class exmo extends Exchange {
},
};
let fee = undefined;
let depositEnabled = undefined;
let withdrawEnabled = undefined;
if (providers === undefined) {
active = true;
type = 'fiat';
Expand All @@ -358,6 +360,20 @@ module.exports = class exmo extends Exchange {
}
const activeProvider = this.safeValue (provider, 'enabled');
limits[type]['enabled'] = activeProvider;
if (type === 'deposit') {
if (activeProvider && !depositEnabled) {
depositEnabled = true;
} else if (!activeProvider) {
depositEnabled = false;
}
}
if (type === 'withdraw') {
if (activeProvider && !withdrawEnabled) {
withdrawEnabled = true;
} else if (!activeProvider) {
withdrawEnabled = false;
}
}
if (activeProvider) {
active = true;
if ((limits[type]['min'] === undefined) || (minValue < limits[type]['min'])) {
Expand All @@ -378,8 +394,8 @@ module.exports = class exmo extends Exchange {
'name': name,
'type': type,
'active': active,
'deposit': undefined,
'withdraw': undefined,
'deposit': depositEnabled,
'withdraw': withdrawEnabled,
'fee': fee,
'precision': 8,
'limits': limits,
Expand Down

0 comments on commit 7f4431f

Please sign in to comment.