diff options
Diffstat (limited to 'bitcoinPayments.js')
| -rw-r--r-- | bitcoinPayments.js | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/bitcoinPayments.js b/bitcoinPayments.js index d3f2f1c4..803a7192 100644 --- a/bitcoinPayments.js +++ b/bitcoinPayments.js @@ -81,7 +81,7 @@ module.exports = (app, bc, db, addresses, payments, emit) => { hash, amount: o.value, currency: user.currency, - rate: app.get("ask"), + rate: app.get("rates")[user.currency], received: true, tip, confirmed, @@ -131,7 +131,12 @@ module.exports = (app, bc, db, addresses, payments, emit) => { await p.save(); let payments = await db.Payment.findAll({ - where: { user_id: user.id }, + where: { + user_id: user.id, + received: { + [Sequelize.Op.ne]: null + }, + }, order: [['id', 'DESC']], limit: 12 }); |
