chore: server code formatting

This commit is contained in:
Rafael Taranto 2025-05-12 15:35:00 +01:00
parent aedabcbdee
commit 68517170e2
234 changed files with 9824 additions and 6195 deletions

View file

@ -10,12 +10,19 @@ const FIAT = ['USD']
const DEFAULT_FIAT_MARKET = 'USD'
const REQUIRED_CONFIG_FIELDS = ['apiKey', 'privateKey', 'currencyMarket']
const loadConfig = (account) => {
const loadConfig = account => {
const mapper = {
'privateKey': 'secret'
privateKey: 'secret',
}
const mapped = _.mapKeys(key => mapper[key] ? mapper[key] : key)(account)
const mapped = _.mapKeys(key => (mapper[key] ? mapper[key] : key))(account)
return { ...mapped, timeout: 3000 }
}
module.exports = { loadConfig, DEFAULT_FIAT_MARKET, REQUIRED_CONFIG_FIELDS, CRYPTO, FIAT, ORDER_TYPE }
module.exports = {
loadConfig,
DEFAULT_FIAT_MARKET,
REQUIRED_CONFIG_FIELDS,
CRYPTO,
FIAT,
ORDER_TYPE,
}