lib/contrast/framework/rails/support.rb in contrast-agent-6.1.0 vs lib/contrast/framework/rails/support.rb in contrast-agent-6.1.1
- old
+ new
@@ -102,11 +102,11 @@
if mounted_app && Contrast::Framework::Grape::Support.grape_controller?(mounted_app)
return mounted_new_grape_route(request, match, path, route, original_url)
end
new_route_coverage = Contrast::Agent::Reporting::RouteCoverage.new
- new_route_coverage.attach_rails_data route, original_url
+ new_route_coverage.attach_rails_data(route, original_url)
rescue StandardError => e
logger.warn('Unable to determine the current route of this request', e)
nil
end
@@ -151,10 +151,10 @@
match, params, route = route_matches.first
# If the current routing node points to a sub-app (::Rais::Engine), dive deeper.
# Have sub-app route the remainder of the url.
if engine_route?(route)
- new_req = retrieve_request request.env
+ new_req = retrieve_request(request.env)
new_req.path_info = new_req.path_info.gsub(match.to_s, '')
get_full_route(new_req, route.app.app.routes.router, path << match.to_s)
else
[match, params, route, path]
end