gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] [taler-merchant-frontend-examples] branch master updated: A


From: gnunet
Subject: [GNUnet-SVN] [taler-merchant-frontend-examples] branch master updated: As wanted to the latest protocol, returing /pay object to the wallet. Used to make the wallet loop.
Date: Mon, 26 Jun 2017 13:03:17 +0200

This is an automated email from the git hooks/post-receive script.

marcello pushed a commit to branch master
in repository merchant-frontend-examples.

The following commit(s) were added to refs/heads/master by this push:
     new a19d3c3  As wanted to the latest protocol, returing /pay object to the 
wallet.  Used to make the wallet loop.
a19d3c3 is described below

commit a19d3c3ef6d3a09ac18604a02c6091ef6b8843dc
Author: Marcello Stanisci <address@hidden>
AuthorDate: Mon Jun 26 12:53:50 2017 +0200

    As wanted to the latest protocol, returing /pay object to the
    wallet.  Used to make the wallet loop.
---
 python/example/example.py | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/python/example/example.py b/python/example/example.py
index 3a64407..2f90392 100644
--- a/python/example/example.py
+++ b/python/example/example.py
@@ -103,13 +103,11 @@ def pay():
     if deposit_permission is None:
         e = flask.jsonify(error="no json in body")
         return e, 400
-
     r = requests.post(urljoin(BACKEND_URL, 'pay'), json=deposit_permission)
     if 200 != r.status_code:
+        logger.error("Backend said, status code: %d, object: %s" % 
(r.status_code, r.text))
         return r.text, r.status_code
     contract_terms = r.json()["contract_terms"]
-
     flask.session["paid"] = True
     flask.session["order_id"] = contract_terms["order_id"]
-
-    return flask.Response(status=200)
+    return flask.jsonify(r.json()), 200

-- 
To stop receiving notification emails like this one, please contact
address@hidden



reply via email to

[Prev in Thread] Current Thread [Next in Thread]