[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] [taler-merchant] 01/02: improve human-readable error messag
From: |
gnunet |
Subject: |
[GNUnet-SVN] [taler-merchant] 01/02: improve human-readable error message (maybe addressing Florians #5258-12809 concern |
Date: |
Fri, 19 Jan 2018 02:24:53 +0100 |
This is an automated email from the git hooks/post-receive script.
grothoff pushed a commit to branch master
in repository merchant.
commit 345c41b73a203ea35b9c622dd2b5a719017a4a29
Author: Christian Grothoff <address@hidden>
AuthorDate: Fri Jan 19 02:24:00 2018 +0100
improve human-readable error message (maybe addressing Florians #5258-12809
concern
---
src/backend/taler-merchant-httpd_tip-pickup.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/src/backend/taler-merchant-httpd_tip-pickup.c
b/src/backend/taler-merchant-httpd_tip-pickup.c
index 76bf7ce..5751747 100644
--- a/src/backend/taler-merchant-httpd_tip-pickup.c
+++ b/src/backend/taler-merchant-httpd_tip-pickup.c
@@ -203,23 +203,27 @@ run_pickup (struct MHD_Connection *connection,
if (TALER_EC_NONE != ec)
{
unsigned int response_code;
+ const char *human;
switch (ec)
{
case TALER_EC_TIP_PICKUP_TIP_ID_UNKNOWN:
response_code = MHD_HTTP_NOT_FOUND;
+ human = "tip identifier not known to this service";
break;
case TALER_EC_TIP_PICKUP_NO_FUNDS:
response_code = MHD_HTTP_SERVICE_UNAVAILABLE;
+ human = "withdrawn funds exceed amounts approved for tip";
break;
default:
response_code = MHD_HTTP_INTERNAL_SERVER_ERROR;
+ human = "database failure";
break;
}
return TMH_RESPONSE_reply_rc (connection,
response_code,
ec,
- "Database error approving tip");
+ human);
}
sigs = json_array ();
GNUNET_CRYPTO_eddsa_key_get_public (&reserve_priv.eddsa_priv,
--
To stop receiving notification emails like this one, please contact
address@hidden