Skip to content
This repository has been archived by the owner on Mar 24, 2021. It is now read-only.

Commit

Permalink
Merge pull request #172 from alphagov/add-request-details-to-response…
Browse files Browse the repository at this point in the history
…-log

Add request method and url to response log
  • Loading branch information
phss committed Nov 22, 2013
2 parents ae89be5 + 9f4ffd0 commit 8e193da
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion backdrop/core/log_handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,10 @@ def log_request():

def create_response_logger(app):
def log_response(response):
app.logger.info("response: %s" % response.status)
app.logger.info(
"response: %s - %s - %s" % (
request.method, request.url, response.status
)
)
return response
return log_response

0 comments on commit 8e193da

Please sign in to comment.