Skip to content

Commit 58626b1

Browse files
committed
use request.path_info
1 parent d3f0936 commit 58626b1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/rails/pagination.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ def _paginate_collection(collection, options={})
3030
collection = ApiPagination.paginate(collection, options)
3131

3232
links = (headers['Link'] || '').split(',').map(&:strip)
33-
url = base_url + request.original_fullpath.sub(/\?.*$/, '')
33+
url = base_url + request.path_info
3434
pages = ApiPagination.pages_from(collection)
3535

3636
pages.each do |k, v|

0 commit comments

Comments
 (0)