1
0
Fork 0
mirror of https://github.com/kaminari/kaminari.git synced 2022-11-09 13:44:37 -05:00

Deprecate Kaminari::PageScopeMethods#num_pages in favor of total_pages

This commit is contained in:
Akira Matsuda 2016-04-15 02:34:01 +09:00 committed by Yuki Nishijima
parent 224a1f977a
commit 6eedbfe10b

View file

@ -30,8 +30,11 @@ module Kaminari
total_pages_count
end
end
#FIXME for compatibility. remove num_pages at some time in the future
alias num_pages total_pages
def num_pages
ActiveSupport::Deprecation.warn 'num_pages is deprecated and will be removed in Kaminari 1.0. Please use total_pages instead.'
total_pages
end
# Current page number
def current_page