From f0e9d59153b172416d83475558dbf0c6eeb96887 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Heiko=20Bernl=C3=B6hr?= Date: Thu, 10 Sep 2020 15:17:07 +0200 Subject: Add logging for http Location header. --- app/controllers/messages_controller.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/app/controllers/messages_controller.rb b/app/controllers/messages_controller.rb index 7eecc7b..2bb9b05 100644 --- a/app/controllers/messages_controller.rb +++ b/app/controllers/messages_controller.rb @@ -247,6 +247,7 @@ protected location += ":" + request.headers["SERVER_PORT"] unless [80,443].include? request.headers["SERVER_PORT"] location += request.headers["SCRIPT_NAME"] if request.headers["SCRIPT_NAME"] location += request.path.gsub(/\/*$/,'') + "/" + @record.id.to_s + logger.info "Location: #{location}" if @app_namespace == 'sys' and @ressource_name == 'auths' render :text => @body, :layout => false, :status => 201, :location => location, :content_type => Mime::Type.lookup_by_extension("json") else -- cgit v1.2.3