mirror of
https://github.com/github/rails.git
synced 2026-04-26 03:00:59 -04:00
Add caller to request_uri deprecation notice
This commit is contained in:
@@ -88,7 +88,7 @@ module ActionDispatch
|
||||
# Returns the request URI, accounting for server idiosyncrasies.
|
||||
# WEBrick includes the full URL. IIS leaves REQUEST_URI blank.
|
||||
def request_uri
|
||||
ActiveSupport::Deprecation.warn "Using #request_uri is deprecated. Use fullpath instead."
|
||||
ActiveSupport::Deprecation.warn "Using #request_uri is deprecated. Use fullpath instead.", caller
|
||||
fullpath
|
||||
end
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@ module Rails
|
||||
|
||||
def before_dispatch(env)
|
||||
request = ActionDispatch::Request.new(env)
|
||||
path = request.request_uri.inspect rescue "unknown"
|
||||
path = request.fullpath.inspect rescue "unknown"
|
||||
|
||||
info "\n\nStarted #{request.method.to_s.upcase} #{path} " <<
|
||||
"for #{request.remote_ip} at #{Time.now.to_s(:db)}"
|
||||
|
||||
Reference in New Issue
Block a user