mirror of
https://github.com/kaminari/kaminari.git
synced 2022-11-09 13:44:37 -05:00
Don't have to carry paginator_class option over the paginator instance
This commit is contained in:
parent
6080b7a32c
commit
23d0bf2d86
1 changed files with 2 additions and 2 deletions
|
@ -22,9 +22,9 @@ module Kaminari
|
|||
# * <tt>:ANY_OTHER_VALUES</tt> - Any other hash key & values would be directly passed into each tag as :locals value.
|
||||
def paginate(scope, options = {})
|
||||
options[:total_pages] ||= scope.total_pages
|
||||
options[:paginator_class] ||= Kaminari::Helpers::Paginator
|
||||
|
||||
paginator = options[:paginator_class].new(self, options.reverse_merge(:current_page => scope.current_page, :per_page => scope.limit_value, :remote => false))
|
||||
paginator_class = options[:paginator_class] || Kaminari::Helpers::Paginator
|
||||
paginator = paginator_class.new(self, options.reverse_merge(:current_page => scope.current_page, :per_page => scope.limit_value, :remote => false))
|
||||
paginator.to_s
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue