commit fc8a45b6ca574a69af384ca18cb4734fba02c282
parent ed93a77ce51c41c52868318bb955e3462e171251
Author: Florian Dold <florian@dold.me>
Date: Wed, 28 May 2025 16:55:16 +0200
consider latest reserve pub row for KYC auth
Sometimes the execution date is the same for multiple withdrawals. Thus
we now also look at the row ID. This is a partial workaround for #10044, but doesn't
fully address the issue yet.
Issue: https://bugs.taler.net/n/10044
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/exchangedb/exchange_do_lookup_kyc_requirement_by_row.sql b/src/exchangedb/exchange_do_lookup_kyc_requirement_by_row.sql
@@ -113,7 +113,7 @@ SELECT reserve_pub
IN (SELECT wire_source_h_payto
FROM wire_targets
WHERE h_normalized_payto=in_h_normalized_payto)
- ORDER BY execution_date DESC
+ ORDER BY execution_date DESC, reserve_in_serial_id DESC
LIMIT 1;
-- FIXME: may want to turn this around and pass *in* the
-- reserve_pub as an argument and then not LIMIT 1 but check