Fix up various flow issues.

This commit is contained in:
Josh Harvey 2017-09-12 00:00:24 +03:00
parent 08bd7da33f
commit 0d8a8547f5
8 changed files with 60 additions and 40 deletions

View file

@ -50,7 +50,7 @@ function toCashOutTx (row) {
function fetchPhoneTx (phone) {
const sql = `select * from cash_out_txs
where phone=$1 and dispense=$2
and (extract(epoch from (coalesce(confirmation_time, now()) - created))) * 1000 < $3`
and (extract(epoch from (coalesce(confirmed_at, now()) - created))) * 1000 < $3`
const values = [phone, false, TRANSACTION_EXPIRATION]