Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

prefer extend over class << self; include; end

  • Loading branch information...
commit d45a762b5bf9a0aefed6411541f98cb7221d96e0 1 parent 7a36ff6
@amatsuda authored
Showing with 1 addition and 3 deletions.
  1. +1 −3 lib/kaminari/models/array_extension.rb
View
4 lib/kaminari/models/array_extension.rb
@@ -14,9 +14,7 @@ def initialize(original_array = [], options = {})
@_original_array, @_limit_value, @_offset_value, @_total_count = original_array, (options[:limit] || default_per_page).to_i, options[:offset].to_i, options[:total_count]
if options[:limit] && options[:offset]
- class << self
- include Kaminari::PageScopeMethods
- end
+ extend Kaminari::PageScopeMethods
end
if options[:total_count]
Please sign in to comment.
Something went wrong with that request. Please try again.