diff options
author | Christian Grothoff <christian@grothoff.org> | 2022-12-29 00:34:36 +0100 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2022-12-29 00:34:36 +0100 |
commit | 5df74558de6e725841c2f5a2ea6f90d0af264c89 (patch) | |
tree | 10d88f1e38abc7281d9c9f8141fe646e0374e691 /src/exchangedb | |
parent | 880c14909bfdaf1199ffc5da989eccb52f6cac12 (diff) | |
download | exchange-5df74558de6e725841c2f5a2ea6f90d0af264c89.tar.xz |
misc purse deletion fixes
Diffstat (limited to 'src/exchangedb')
-rw-r--r-- | src/exchangedb/exchange_do_purse_delete.sql (renamed from src/exchangedb/exchange_do_delete_purse.sql) | 8 | ||||
-rw-r--r-- | src/exchangedb/procedures.sql.in | 2 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/exchangedb/exchange_do_delete_purse.sql b/src/exchangedb/exchange_do_purse_delete.sql index a57f25454..096475b43 100644 --- a/src/exchangedb/exchange_do_delete_purse.sql +++ b/src/exchangedb/exchange_do_purse_delete.sql @@ -14,7 +14,7 @@ -- TALER; see the file COPYING. If not, see <http://www.gnu.org/licenses/> -- -CREATE OR REPLACE FUNCTION exchange_do_delete_purse( +CREATE OR REPLACE FUNCTION exchange_do_purse_delete( IN in_purse_pub BYTEA, IN in_purse_sig BYTEA, IN in_now INT8, @@ -28,7 +28,7 @@ DECLARE my_in_reserve_quota BOOLEAN; BEGIN -SELECT COUNT(*) FROM purse_decision +PERFORM refunded FROM purse_decision WHERE purse_pub=in_purse_pub; IF FOUND THEN @@ -49,7 +49,7 @@ THEN END IF; -- store reserve deletion -INSERT INTO purse_deletion +INSERT INTO exchange.purse_deletion (purse_pub ,purse_sig) VALUES @@ -115,5 +115,5 @@ END LOOP; END $$; -COMMENT ON FUNCTION exchange_do_delete_purse(BYTEA,BYTEA,INT8) +COMMENT ON FUNCTION exchange_do_purse_delete(BYTEA,BYTEA,INT8) IS 'Delete a previously undecided purse and refund the coins (if any).'; diff --git a/src/exchangedb/procedures.sql.in b/src/exchangedb/procedures.sql.in index af47bbf63..194830248 100644 --- a/src/exchangedb/procedures.sql.in +++ b/src/exchangedb/procedures.sql.in @@ -28,11 +28,11 @@ SET search_path TO exchange; #include "exchange_do_recoup_to_reserve.sql" #include "exchange_do_recoup_to_coin.sql" #include "exchange_do_gc.sql" +#include "exchange_do_purse_delete.sql" #include "exchange_do_purse_deposit.sql" #include "exchange_do_purse_merge.sql" #include "exchange_do_reserve_purse.sql" #include "exchange_do_expire_purse.sql" -#include "exchange_do_delete_purse.sql" #include "exchange_do_history_request.sql" #include "exchange_do_reserve_open_deposit.sql" #include "exchange_do_reserve_open.sql" |