Skip to content

Commit

Permalink
Avoid deprecated use of Rack::Request#[] (#386)
Browse files Browse the repository at this point in the history
  • Loading branch information
semaperepelitsa authored and SamSaffron committed Jun 18, 2019
1 parent 61ec68e commit ad9ca84
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/mini_profiler/profiler.rb
Expand Up @@ -84,11 +84,11 @@ def user(env)

def serve_results(env)
request = Rack::Request.new(env)
id = request[:id]
id = request.params['id']
page_struct = @storage.load(id)
unless page_struct
@storage.set_viewed(user(env), id)
id = ERB::Util.html_escape(request['id'])
id = ERB::Util.html_escape(request.params['id'])
user_info = ERB::Util.html_escape(user(env))
return [404, {}, ["Request not found: #{id} - user #{user_info}"]]
end
Expand Down

0 comments on commit ad9ca84

Please sign in to comment.