only log session_id if @session object responds to .session_id.

In functional test cases you often pass in a hash as session object which doesn't have this method. 


git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3339 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
This commit is contained in:
Tobias Lütke
2005-12-22 21:16:11 +00:00
parent 4e76ae3904
commit 373bc86d2d

View File

@@ -846,7 +846,7 @@ module ActionController #:nodoc:
def log_processing
logger.info "\n\nProcessing #{controller_class_name}\##{action_name} (for #{request_origin}) [#{request.method.to_s.upcase}]"
logger.info " Session ID: #{@session.session_id}" if @session
logger.info " Session ID: #{@session.session_id}" if @session and @session.respond_to?(:session_id)
logger.info " Parameters: #{@params.inspect}"
end