Skip to content

Commit

Permalink
avoid "instance variable @_default_per_page not initialized" warning
Browse files Browse the repository at this point in the history
  • Loading branch information
amatsuda committed Feb 14, 2012
1 parent 7cb1827 commit eaca75e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/kaminari/models/configuration_methods.rb
Expand Up @@ -13,7 +13,7 @@ def paginates_per(val)
# This model's default +per_page+ value
# returns +default_per_page+ value unless explicitly overridden via <tt>paginates_per</tt>
def default_per_page
@_default_per_page || Kaminari.config.default_per_page
@_default_per_page ||= Kaminari.config.default_per_page
end
end
end
Expand Down

0 comments on commit eaca75e

Please sign in to comment.