gnunet-svn
[Top][All Lists]
Advanced

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

[GNUnet-SVN] [taler-blog] branch master updated: some linting


From: gnunet
Subject: [GNUnet-SVN] [taler-blog] branch master updated: some linting
Date: Fri, 29 Dec 2017 15:40:03 +0100

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

marcello pushed a commit to branch master
in repository blog.

The following commit(s) were added to refs/heads/master by this push:
     new 3ce3aeb  some linting
3ce3aeb is described below

commit 3ce3aeb07c087e1dc8ff497f1c0f0dc495fc1fc1
Author: Marcello Stanisci <address@hidden>
AuthorDate: Fri Dec 29 15:39:45 2017 +0100

    some linting
---
 talerblog/blog/blog.py | 12 +++++-------
 1 file changed, 5 insertions(+), 7 deletions(-)

diff --git a/talerblog/blog/blog.py b/talerblog/blog/blog.py
index 8a48883..54d77f0 100644
--- a/talerblog/blog/blog.py
+++ b/talerblog/blog/blog.py
@@ -79,9 +79,7 @@ def refund():
     if flask.request.method == "POST":
         payed_articles = flask.session["payed_articles"] = 
flask.session.get("payed_articles", {})
         article_name = flask.request.form.get("article_name")
-        if not article_name:
-            return flask.jsonify(dict(error="No article_name found in form")), 
400
-        LOGGER.info("Looking for %s to refund" % article_name)
+        LOGGER.info("Looking for article '%s' to refund" % article_name)
         order_id = payed_articles.get(article_name)
         if not order_id:
             return flask.jsonify(dict(error="Aborting refund: article not 
payed")), 401
@@ -160,15 +158,15 @@ def article(name, data=None):
         return flask.render_template("templates/article_refunded.html", 
article_name=name)
 
     if name in payed_articles:
-        articleInfo = ARTICLES[name]
-        if articleInfo is None:
+        article_info = ARTICLES[name]
+        if article_info is None:
             flask.abort(500)
         if data is not None:
-            if data in articleInfo.extra_files:
+            if data in article_info.extra_files:
                 return flask.send_file(get_image_file(data))
             return "permission denied", 400
         return flask.render_template("templates/article_frame.html",
-                                     
article_file=get_article_file(articleInfo),
+                                     
article_file=get_article_file(article_info),
                                      article_name=name)
 
     contract_url = make_url("/generate-contract",

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



reply via email to

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