roger 1.6.2 → 1.6.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +3 -0
- data/lib/roger/renderer.rb +4 -0
- data/lib/roger/version.rb +1 -1
- data/test/unit/renderer/renderer_base_test.rb +6 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 08b47d99903f3d3eead1bac65ee0b5f12d87be52
|
4
|
+
data.tar.gz: ac530d446306f7891cae517fe062cef21b4af25a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 25315c6c7e964d202919de443d9d8045379d817737a5cf81b2dcf104ffaffafc128c1b4a183a6d21a03990e1ca7c0ec10586b4c86830ee258c40a381fd151ba3
|
7
|
+
data.tar.gz: b40b87fe2d800010d15d23fe2104909f3d3998df83a3c17749faa6cba5f2aa8fd77df16ba154da9bdee38c5671b25d64bd9ce4076012b4a5f56a00b4d264d22e
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,8 @@
|
|
1
1
|
# Changelog
|
2
2
|
|
3
|
+
## Version 1.6.3
|
4
|
+
* Fix issue with `render_file` screwing up the current_template nesting stack.
|
5
|
+
|
3
6
|
## Version 1.6.2
|
4
7
|
* Allow for tempalte recursion for up to 10 levels.
|
5
8
|
* Fix issue with missing partials that would screw up the current_template nesting stack.
|
data/lib/roger/renderer.rb
CHANGED
@@ -154,6 +154,10 @@ module Roger
|
|
154
154
|
template_nesting.push(template)
|
155
155
|
|
156
156
|
template.render(options[:locals] || {})
|
157
|
+
ensure
|
158
|
+
# Only pop the template from the nesting if we actually
|
159
|
+
# put it on the nesting stack.
|
160
|
+
template_nesting.pop if template
|
157
161
|
end
|
158
162
|
|
159
163
|
# The current template being rendered
|
data/lib/roger/version.rb
CHANGED
@@ -42,6 +42,12 @@ module Roger
|
|
42
42
|
end
|
43
43
|
end
|
44
44
|
|
45
|
+
def test_render_file_pop_nesting
|
46
|
+
assert_equal nil, @renderer.current_template
|
47
|
+
@renderer.render_file(@base + "html/renderer/file.html.erb")
|
48
|
+
assert_equal nil, @renderer.current_template
|
49
|
+
end
|
50
|
+
|
45
51
|
# Formats
|
46
52
|
|
47
53
|
def test_render_md
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: roger
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.6.
|
4
|
+
version: 1.6.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Flurin Egger
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2016-
|
13
|
+
date: 2016-10-05 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: thor
|