From 7159402c6d0edab20ff84a686bcd03894b4e9c4c Mon Sep 17 00:00:00 2001 From: David Heinemeier Hansson Date: Sat, 21 May 2005 17:50:57 +0000 Subject: Fixed use of an integer as return code for renders, so render_text "hello world", 404 now works #1327 git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1345 5ecf4fe2-1ee6-0310-87b1-e25e094e27de --- actionpack/lib/action_controller/base.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'actionpack/lib/action_controller') diff --git a/actionpack/lib/action_controller/base.rb b/actionpack/lib/action_controller/base.rb index 416388dfa7..160318c98b 100755 --- a/actionpack/lib/action_controller/base.rb +++ b/actionpack/lib/action_controller/base.rb @@ -478,7 +478,7 @@ module ActionController #:nodoc: def render_text(text = nil, status = nil, &block) #:doc: return if performed? add_variables_to_assigns - @response.headers["Status"] = status || DEFAULT_RENDER_STATUS_CODE + @response.headers["Status"] = status.to_s || DEFAULT_RENDER_STATUS_CODE @response.body = block_given? ? block : text @performed_render = true end -- cgit v1.2.3