diff --git a/lib/plugins/wallet-scoring/ciphertrace/ciphertrace.js b/lib/plugins/wallet-scoring/ciphertrace/ciphertrace.js index 74668b09..d82caf7a 100644 --- a/lib/plugins/wallet-scoring/ciphertrace/ciphertrace.js +++ b/lib/plugins/wallet-scoring/ciphertrace/ciphertrace.js @@ -1,8 +1,6 @@ const axios = require('axios') const _ = require('lodash/fp') -const { WALLET_SCORE_THRESHOLD } = require('../../../constants') - const NAME = 'CipherTrace' const SUPPORTED_COINS = ['BTC', 'ETH', 'BCH', 'LTC', 'BNB', 'RSK'] @@ -26,7 +24,7 @@ function rateWallet(account, cryptoCode, address) { if (!_.includes(_.toUpper(cryptoCode), SUPPORTED_COINS) || _.isNil(client)) return Promise.resolve(null) const { apiVersion, authHeader } = client - const threshold = _.isNil(account) ? WALLET_SCORE_THRESHOLD : account.scoreThreshold + const threshold = account.scoreThreshold return axios.get(`https://rest.ciphertrace.com/aml/${apiVersion}/${_.toLower(cryptoCode)}/risk?address=${address}`, { headers: authHeader @@ -38,7 +36,7 @@ function isValidWalletScore(account, score) { const client = getClient(account) if (_.isNil(client)) return Promise.resolve(true) - const threshold = _.isNil(account) ? WALLET_SCORE_THRESHOLD : account.scoreThreshold + const threshold = account.scoreThreshold return Promise.resolve(score < threshold) }