Skip to content

Commit

Permalink
[#20240705] Update logging to include REQUEST_URI
Browse files Browse the repository at this point in the history
  • Loading branch information
delano committed Jul 13, 2024
1 parent 940470b commit 692e6da
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions lib/middleware/handle_invalid_percent_encoding.rb
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,7 @@ def handle_exception(env, exception)
rack_input = env['rack.input']&.read || ''
errmsg = exception.message

message = "`#{errmsg}` in one of the following params: #{rack_input}"
logger.error "[handle-invalid-uri-encoding] #{message}"
logger.error "[handle-invalid-uri-encoding] #{errmsg} in #{env['REQUEST_URI']}"

status = 400
body = { error: 'Bad Request', message: errmsg }.to_json
Expand Down

0 comments on commit 692e6da

Please sign in to comment.