diff options
author | Marcello Stanisci <marcello.stanisci@inria.fr> | 2017-05-02 09:06:50 +0200 |
---|---|---|
committer | Marcello Stanisci <marcello.stanisci@inria.fr> | 2017-05-02 09:07:05 +0200 |
commit | 9b44e57e298fea93a51457d4826562a9fb75d942 (patch) | |
tree | 96e973c13448755db2c93f0cafc8f334f30e617d /src | |
parent | ee0fb929d7bcb1dbcaf29ef88a38ad9b5e89e756 (diff) | |
download | merchant-9b44e57e298fea93a51457d4826562a9fb75d942.tar.gz merchant-9b44e57e298fea93a51457d4826562a9fb75d942.tar.bz2 merchant-9b44e57e298fea93a51457d4826562a9fb75d942.zip |
make_response() called in one place
Diffstat (limited to 'src')
-rw-r--r-- | src/mitm/talermerchantmitm/mitm.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mitm/talermerchantmitm/mitm.py b/src/mitm/talermerchantmitm/mitm.py index 6975f210..a9180fd2 100644 --- a/src/mitm/talermerchantmitm/mitm.py +++ b/src/mitm/talermerchantmitm/mitm.py @@ -42,10 +42,10 @@ assert(None != exchange_url) # modifying the data to return. def track_transaction(resp): - return resp + return resp.text def track_transfer(resp): - return resp + return resp.text @app.route('/', defaults={'path': ''}) @app.route('/<path:path>', methods=["GET", "POST"]) @@ -65,8 +65,8 @@ def all(path): "track_transfer": track_transfer } func = dispatcher.get(request.headers.get("X-Taler-Mitm"), - lambda x: make_response(x.text)) - response = func(r) + lambda x: x.text) + response = make_response(func(r)) for key, value in r.headers.items(): if key not in ("Server", "Content-Length"): response.headers[key] = value |