exchange

Base system with REST service to issue digital coins, run by the payment service provider
Log | Files | Refs | Submodules | README | LICENSE

commit e3da5b29072b8254039675ae250f69da753171ec
parent c15667b38d3d2688472aeff7578116ac940150aa
Author: Sebastian <sebasjm@gmail.com>
Date:   Thu, 14 Sep 2023 15:52:42 -0300

fix: reserve_found NULL when the reserve is partially filled

Diffstat:
Msrc/exchangedb/exchange_do_batch_withdraw.sql | 3+--
1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/src/exchangedb/exchange_do_batch_withdraw.sql b/src/exchangedb/exchange_do_batch_withdraw.sql @@ -56,6 +56,7 @@ THEN ruuid=2; RETURN; END IF; +reserve_found=TRUE; ruuid = reserve.reserve_uuid; @@ -73,7 +74,6 @@ ELSE not_before=date '1970-01-01' + reserve.birthday; allowed_maximum_age = extract(year from age(current_date, not_before)); - reserve_found=TRUE; balance_ok=FALSE; age_ok = FALSE; RETURN; @@ -113,7 +113,6 @@ UPDATE reserves SET WHERE reserves.reserve_pub=rpub; -reserve_found=TRUE; balance_ok=TRUE; END $$;