changes to limit

This commit is contained in:
albert
2013-01-14 16:04:05 -05:00
parent 493990dae1
commit 0cd009df24
3 changed files with 7 additions and 5 deletions

View File

@@ -66,7 +66,7 @@ module Danbooru
def records_per_page
# ugly hack but no easy way to pass this info down
Thread.current["records_per_page"] || Danbooru.config.posts_per_page
(@paginator_options[:limit] || Thread.current["records_per_page"] || Danbooru.config.posts_per_page).to_i
end
# taken from kaminari (https://github.com/amatsuda/kaminari)