kaminari 0.10.0 → 0.10.1
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of kaminari might be problematic. Click here for more details.
- data/CHANGELOG +5 -0
- data/VERSION +1 -1
- data/kaminari.gemspec +1 -1
- data/lib/kaminari/helpers/tags.rb +6 -2
- metadata +3 -3
data/CHANGELOG
CHANGED
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.10.
|
1
|
+
0.10.1
|
data/kaminari.gemspec
CHANGED
@@ -73,13 +73,17 @@ module Kaminari
|
|
73
73
|
def initialize(template, window_options) #:nodoc:
|
74
74
|
@template, @options = template, window_options.reverse_merge(template.options)
|
75
75
|
# so that this instance can actually "render". Black magic?
|
76
|
-
@output_buffer = @template.output_buffer
|
76
|
+
@output_buffer = @template.output_buffer
|
77
|
+
if @output_buffer.nil?
|
78
|
+
@output_buffer, @return_buffer = ActionView::OutputBuffer.new, true
|
79
|
+
end
|
77
80
|
end
|
78
81
|
|
79
82
|
# render given block as a view template
|
80
83
|
def render(&block)
|
81
84
|
instance_eval &block if @options[:num_pages] > 1
|
82
|
-
|
85
|
+
# return the output text only if the output_buffer was created inside this instance
|
86
|
+
@return_buffer ? @output_buffer : nil
|
83
87
|
end
|
84
88
|
|
85
89
|
# enumerate each page providing PageProxy object as the block parameter
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: kaminari
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 53
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 10
|
9
|
-
-
|
10
|
-
version: 0.10.
|
9
|
+
- 1
|
10
|
+
version: 0.10.1
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Akira Matsuda
|