From ade756fe42423033bae8e5aea8f58782f7a6c517 Mon Sep 17 00:00:00 2001 From: Jeremy Kemper Date: Sun, 16 May 2010 13:52:51 -0700 Subject: Moved encoding work in progress to a feature branch. This reverts commits af0d1a88157942c6e6398dbf73891cff1e152405 and 64d109e3539ad600f58536d3ecabd2f87b67fd1c. --- actionpack/lib/action_view/template/resolver.rb | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'actionpack/lib/action_view/template/resolver.rb') diff --git a/actionpack/lib/action_view/template/resolver.rb b/actionpack/lib/action_view/template/resolver.rb index ef44925951..a223b3a55f 100644 --- a/actionpack/lib/action_view/template/resolver.rb +++ b/actionpack/lib/action_view/template/resolver.rb @@ -70,10 +70,7 @@ module ActionView Dir[query].reject { |p| File.directory?(p) }.map do |p| handler, format = extract_handler_and_format(p, formats) - - contents = File.open(p, "rb") {|io| io.read } - - Template.new(contents, File.expand_path(p), handler, + Template.new(File.read(p), File.expand_path(p), handler, :virtual_path => path, :format => format) end end -- cgit v1.2.3