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

make sure it runs on 3.0

This commit is contained in:
Akira Matsuda 2011-02-11 03:22:47 +09:00
parent 03d7553284
commit bf24b4c2c4

View file

@ -30,7 +30,13 @@ module Kaminari
end end
def args_for_lookup(klass) def args_for_lookup(klass)
@renderer.context.send :args_for_lookup, klass.template_filename, 'kaminari', true, [] if (method = @renderer.context.method :args_for_lookup).arity == 3
# 3.0
method.call klass.template_filename, 'kaminari', true
else
# 3.1
method.call klass.template_filename, 'kaminari', true, []
end
end end
def page_url_for(page) def page_url_for(page)