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

Prefer simpler code

This commit is contained in:
Akira Matsuda 2016-11-23 13:08:19 +09:00
parent 8763cad3d7
commit 315e06bcc4

View file

@ -49,7 +49,7 @@ module Kaminari
prev_page = path_to_prev_page(scope, options)
options.except! :params, :param_name
options.reverse_merge! rel: 'prev'
options[:rel] ||= 'prev'
link_to_if prev_page, name, prev_page, options do
yield if block_given?
@ -77,7 +77,7 @@ module Kaminari
next_page = path_to_next_page(scope, options)
options.except! :params, :param_name
options.reverse_merge! rel: 'next'
options[:rel] ||= 'next'
link_to_if next_page, name, next_page, options do
yield if block_given?