Expired transaction after bugfix (#121)

* other minor fixes

* reedemable transaction expiry fix
This commit is contained in:
Fabio Cigliano 2018-06-13 01:15:58 +12:00 committed by Josh Harvey
parent 25030fab2a
commit 63e0782e32
3 changed files with 13 additions and 3 deletions

View file

@ -138,6 +138,10 @@ function authorizeZeroConf (settings, tx, machineId) {
const plugin = cryptoConfig.zeroConf
const zeroConfLimit = machineConfig.zeroConfLimit
if (!_.isObject(tx.fiat)) {
return Promise.reject(new Error('tx.fiat is undefined!'))
}
if (plugin === 'no-zero-conf' || tx.fiat.gt(zeroConfLimit)) {
return Promise.resolve(false)
}