fix : htf
This commit is contained in:
@@ -75,13 +75,17 @@ const FundSchema = new mongoose.Schema({
|
|||||||
|
|
||||||
const FundModel = mongoose.model('Fund', FundSchema);
|
const FundModel = mongoose.model('Fund', FundSchema);
|
||||||
|
|
||||||
FundModel.prototype.hasNewDeposit = async function () {
|
FundModel.prototype.hasNewDeposit = async () => {
|
||||||
if (this.tokenAddress.usdtETH) {
|
if (this.tokenAddress.usdtETH) {
|
||||||
const usdtTx = await getUSDTTxList(this.tokenAddress.usdtETH.address);
|
const usdtTx = await getUSDTTxList(this.tokenAddress.usdtETH.address);
|
||||||
const fundList = this.fundList;
|
if (usdtTx && usdtTx.length > 0) {
|
||||||
const newDepositList = getNewDepositTx(usdtTx, fundList);
|
const fundList = this.fundList;
|
||||||
if (newDepositList && newDepositList.length > 0)
|
const newDepositList = getNewDepositTx(usdtTx, fundList);
|
||||||
return { hasNew: true, list: newDepositList };
|
if (newDepositList && newDepositList.length > 0) {
|
||||||
|
mylog.info(`用户${this.userId} 有新的充值记录`);
|
||||||
|
return { hasNew: true, list: newDepositList };
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return { hasNew: false };
|
return { hasNew: false };
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user