render_parent 0.0.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.2
1
+ 0.0.3
@@ -3,7 +3,7 @@ require 'action_view/base'
3
3
  ActionView::Base.class_eval do
4
4
  def render_parent_template(local_assigns = {}, &block)
5
5
  view_paths.exclusions << template
6
- result = render({:file => template.to_s}, local_assigns, &block)
6
+ result = render(:file => template.to_s, :locals => local_assigns, &block)
7
7
  view_paths.exclusions.delete template
8
8
  result
9
9
  end
@@ -5,7 +5,7 @@ ActionView::Helpers::RenderingHelper.module_eval do
5
5
  def render_parent_template(locals = {}, &block)
6
6
  template = controller.active_template
7
7
  view_paths.exclusions << template
8
- result = render({:file => template.virtual_path}, locals, &block)
8
+ result = render(:file => template.virtual_path, :locals => locals, &block)
9
9
  view_paths.exclusions.delete template
10
10
  result
11
11
  end
@@ -29,11 +29,12 @@ ActionView::PathSet.class_eval do
29
29
  end
30
30
 
31
31
  def find_all_with_exclusions(path, prefixes = [], *args)
32
+ excluded = exclusions.map(&:identifier)
32
33
  prefixes = [prefixes] if String === prefixes
33
34
  prefixes.each do |prefix|
34
35
  paths.each do |resolver|
35
36
  templates = resolver.find_all(path, prefix, *args)
36
- templates.delete_if {|t| exclusions.include? t}
37
+ templates.delete_if {|t| excluded.include? t.identifier}
37
38
  return templates unless templates.empty?
38
39
  end
39
40
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: render_parent
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.3
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-10-11 00:00:00.000000000 Z
12
+ date: 2012-10-12 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rails
@@ -97,7 +97,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
97
97
  version: '0'
98
98
  segments:
99
99
  - 0
100
- hash: 117922609
100
+ hash: 855342721
101
101
  required_rubygems_version: !ruby/object:Gem::Requirement
102
102
  none: false
103
103
  requirements: