diff options
author | Florian Dold <florian@dold.me> | 2023-02-14 13:10:38 +0100 |
---|---|---|
committer | Florian Dold <florian@dold.me> | 2023-02-14 13:10:38 +0100 |
commit | e3bdfe61a8907704d8eb787acaf6e63253a905f9 (patch) | |
tree | 4b6d23d098a2969fed5cc266b800eb089a9dc98a /packages | |
parent | 55f868d5e83f577cd20ad6f33e0cf8776b4d0f45 (diff) |
-fix schema validation
Diffstat (limited to 'packages')
-rw-r--r-- | packages/taler-util/src/transactions-types.ts | 2 | ||||
-rw-r--r-- | packages/taler-wallet-core/src/operations/transactions.ts | 3 |
2 files changed, 5 insertions, 0 deletions
diff --git a/packages/taler-util/src/transactions-types.ts b/packages/taler-util/src/transactions-types.ts index 98e333ad3..7d5cb9ae1 100644 --- a/packages/taler-util/src/transactions-types.ts +++ b/packages/taler-util/src/transactions-types.ts @@ -42,6 +42,7 @@ import { codecForString, codecForList, codecForAny, + codecForBoolean, } from "./codec.js"; import { RefreshReason, @@ -586,6 +587,7 @@ export const codecForTransactionsRequest = (): Codec<TransactionsRequest> => buildCodecForObject<TransactionsRequest>() .property("currency", codecOptional(codecForString())) .property("search", codecOptional(codecForString())) + .property("includeRefreshes", codecOptional(codecForBoolean())) .build("TransactionsRequest"); // FIXME: do full validation here! diff --git a/packages/taler-wallet-core/src/operations/transactions.ts b/packages/taler-wallet-core/src/operations/transactions.ts index 9ebd87cc0..277c219e1 100644 --- a/packages/taler-wallet-core/src/operations/transactions.ts +++ b/packages/taler-wallet-core/src/operations/transactions.ts @@ -24,6 +24,7 @@ import { constructPayPullUri, constructPayPushUri, ExtendedStatus, + j2s, Logger, OrderShortInfo, PaymentStatus, @@ -958,6 +959,8 @@ export async function getTransactions( transactions.push(buildTransactionForPullPaymentDebit(pi)); }); + logger.info(`tx request: ${j2s(transactionsRequest)}`); + if (transactionsRequest?.includeRefreshes) { tx.refreshGroups.iter().forEachAsync(async (rg) => { if (shouldSkipCurrency(transactionsRequest, rg.currency)) { |