diff options
author | Burke Libbey <burke@burkelibbey.org> | 2011-05-06 14:02:31 -0500 |
---|---|---|
committer | Burke Libbey <burke@burkelibbey.org> | 2011-05-06 14:02:31 -0500 |
commit | 156039c4cf7f0e0ad697443b121b46d3fe57d801 (patch) | |
tree | 6197ccd5d9d98abe65f0719817180617d962856e /actionpack/lib/action_view | |
parent | 30d49d001e9060d1898722dfa43b61b7daf90cd4 (diff) | |
download | rails-156039c4cf7f0e0ad697443b121b46d3fe57d801.tar.gz rails-156039c4cf7f0e0ad697443b121b46d3fe57d801.tar.bz2 rails-156039c4cf7f0e0ad697443b121b46d3fe57d801.zip |
Added a test for MissingTemplate change, and changed to use Array.wrap() as
requested by josevalim.
Diffstat (limited to 'actionpack/lib/action_view')
-rw-r--r-- | actionpack/lib/action_view/path_set.rb | 2 | ||||
-rw-r--r-- | actionpack/lib/action_view/template/error.rb | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/actionpack/lib/action_view/path_set.rb b/actionpack/lib/action_view/path_set.rb index 8b840a6463..1e38b82852 100644 --- a/actionpack/lib/action_view/path_set.rb +++ b/actionpack/lib/action_view/path_set.rb @@ -15,7 +15,7 @@ module ActionView #:nodoc: end def find_all(path, prefixes = [], *args) - prefixes = [prefixes] if String === prefixes + prefixes = Array.wrap(prefixes) if String === prefixes prefixes.each do |prefix| each do |resolver| templates = resolver.find_all(path, prefix, *args) diff --git a/actionpack/lib/action_view/template/error.rb b/actionpack/lib/action_view/template/error.rb index fa7a620daa..6eec0cc23d 100644 --- a/actionpack/lib/action_view/template/error.rb +++ b/actionpack/lib/action_view/template/error.rb @@ -29,7 +29,7 @@ module ActionView def initialize(paths, path, prefixes, partial, details, *) @path = path - prefixes = [prefixes] if String === prefixes + prefixes = Array.wrap(prefixes) if String === prefixes display_paths = paths.compact.map{ |p| p.to_s.inspect }.join(", ") template_type = if partial "partial" |