Added a log_response middleware