diff options
author | Sebastian <sebasjm@gmail.com> | 2023-12-10 18:35:51 -0300 |
---|---|---|
committer | Sebastian <sebasjm@gmail.com> | 2023-12-10 18:35:51 -0300 |
commit | 22c5b472b839f48a045270961c748b8bcef3355f (patch) | |
tree | f2ba4af093f1ad6827f998743d6cdad2f986c04e /packages/taler-util/src | |
parent | f7d4bfdd0c38a37d4fd50e947deccc8ab9da921a (diff) | |
download | wallet-core-22c5b472b839f48a045270961c748b8bcef3355f.tar.xz |
all taler-action URI should end with slash
Diffstat (limited to 'packages/taler-util/src')
-rw-r--r-- | packages/taler-util/src/taleruri.ts | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/packages/taler-util/src/taleruri.ts b/packages/taler-util/src/taleruri.ts index cf5d3f413..47b646565 100644 --- a/packages/taler-util/src/taleruri.ts +++ b/packages/taler-util/src/taleruri.ts @@ -659,7 +659,7 @@ export function stringifyPayUri({ c: claimToken, n: noncePriv, }); - return `${proto}://pay/${path}${orderId}/${sessionId}${query}`; + return `${proto}://pay/${path}${orderId}/${sessionId}/${query}`; } export function stringifyPayPullUri({ @@ -667,7 +667,7 @@ export function stringifyPayPullUri({ exchangeBaseUrl, }: Omit<PayPullUriResult, "type">): string { const { proto, path } = getUrlInfo(exchangeBaseUrl); - return `${proto}://pay-pull/${path}${contractPriv}`; + return `${proto}://pay-pull/${path}${contractPriv}/`; } export function stringifyPayPushUri({ @@ -676,7 +676,7 @@ export function stringifyPayPushUri({ }: Omit<PayPushUriResult, "type">): string { const { proto, path } = getUrlInfo(exchangeBaseUrl); - return `${proto}://pay-push/${path}${contractPriv}`; + return `${proto}://pay-push/${path}${contractPriv}/`; } export function stringifyRestoreUri({ @@ -697,13 +697,13 @@ export function stringifyWithdrawExchange({ const { proto, path, query } = getUrlInfo(exchangeBaseUrl, { a: amount, }); - return `${proto}://withdraw-exchange/${path}${exchangePub}${query}`; + return `${proto}://withdraw-exchange/${path}${exchangePub}/${query}`; } export function stringifyDevExperimentUri({ devExperimentId, }: Omit<DevExperimentUri, "type">): string { - return `taler://dev-experiment/${devExperimentId}`; + return `taler://dev-experiment/${devExperimentId}/`; } export function stringifyPayTemplateUri({ @@ -712,21 +712,21 @@ export function stringifyPayTemplateUri({ templateParams, }: Omit<PayTemplateUriResult, "type">): string { const { proto, path, query } = getUrlInfo(merchantBaseUrl, templateParams); - return `${proto}://pay-template/${path}${templateId}${query}`; + return `${proto}://pay-template/${path}${templateId}/${query}`; } export function stringifyRefundUri({ merchantBaseUrl, orderId, }: Omit<RefundUriResult, "type">): string { const { proto, path } = getUrlInfo(merchantBaseUrl); - return `${proto}://refund/${path}${orderId}`; + return `${proto}://refund/${path}${orderId}/`; } export function stringifyRewardUri({ merchantBaseUrl, merchantRewardId, }: Omit<RewardUriResult, "type">): string { const { proto, path } = getUrlInfo(merchantBaseUrl); - return `${proto}://reward/${path}${merchantRewardId}`; + return `${proto}://reward/${path}${merchantRewardId}/`; } export function stringifyExchangeUri({ @@ -734,7 +734,7 @@ export function stringifyExchangeUri({ exchangePub, }: Omit<ExchangeUri, "type">): string { const { proto, path } = getUrlInfo(exchangeBaseUrl); - return `${proto}://exchange/${path}${exchangePub}`; + return `${proto}://exchange/${path}${exchangePub}/`; } export function stringifyAuditorUri({ @@ -742,7 +742,7 @@ export function stringifyAuditorUri({ auditorPub, }: Omit<AuditorUri, "type">): string { const { proto, path } = getUrlInfo(auditorBaseUrl); - return `${proto}://auditor/${path}${auditorPub}`; + return `${proto}://auditor/${path}${auditorPub}/`; } export function stringifyWithdrawUri({ @@ -750,7 +750,7 @@ export function stringifyWithdrawUri({ withdrawalOperationId, }: Omit<WithdrawUriResult, "type">): string { const { proto, path } = getUrlInfo(bankIntegrationApiBaseUrl); - return `${proto}://withdraw/${path}${withdrawalOperationId}`; + return `${proto}://withdraw/${path}${withdrawalOperationId}/`; } /** |