aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFlorian Dold <florian@dold.me>2024-04-02 13:03:01 +0200
committerFlorian Dold <florian@dold.me>2024-04-02 13:03:01 +0200
commitb4185a6ef452fba47e481264af06e67524391584 (patch)
tree90458c6672950515d42ce5d4c9e30ad986cb0ebf
parentb9a0a16a91c06c50a93f7ba3980c874016a32fb6 (diff)
-error codes
-rw-r--r--packages/taler-util/src/taleruri.ts12
1 files changed, 6 insertions, 6 deletions
diff --git a/packages/taler-util/src/taleruri.ts b/packages/taler-util/src/taleruri.ts
index 0022a72cc..db8a58185 100644
--- a/packages/taler-util/src/taleruri.ts
+++ b/packages/taler-util/src/taleruri.ts
@@ -139,8 +139,8 @@ export function parseWithdrawUriWithError(s: string) {
const parts = pi.body.rest.split("/");
if (parts.length < 2) {
- return opKnownTalerFailure(TalerErrorCode.TALER_URI_NO_ENOUGH_COMPONENT, {
- code: TalerErrorCode.TALER_URI_NO_ENOUGH_COMPONENT,
+ return opKnownTalerFailure(TalerErrorCode.WALLET_TALER_URI_MALFORMED, {
+ code: TalerErrorCode.WALLET_TALER_URI_MALFORMED,
});
}
@@ -236,8 +236,8 @@ function parseProtoInfoWithError(s: string, action: string) {
!s.toLowerCase().startsWith("taler://") &&
!s.toLowerCase().startsWith("taler+http://")
) {
- return opKnownTalerFailure(TalerErrorCode.TALER_URI_PREFIX, {
- code: TalerErrorCode.TALER_URI_PREFIX,
+ return opKnownTalerFailure(TalerErrorCode.WALLET_TALER_URI_MALFORMED, {
+ code: TalerErrorCode.WALLET_TALER_URI_MALFORMED,
});
}
const pfxPlain = `taler://${action}/`;
@@ -253,8 +253,8 @@ function parseProtoInfoWithError(s: string, action: string) {
rest: s.substring(pfxHttp.length),
});
} else {
- return opKnownTalerFailure(TalerErrorCode.TALER_URI_UNKOWN_ACTION, {
- code: TalerErrorCode.TALER_URI_UNKOWN_ACTION,
+ return opKnownTalerFailure(TalerErrorCode.WALLET_TALER_URI_MALFORMED, {
+ code: TalerErrorCode.WALLET_TALER_URI_MALFORMED,
});
}
}