Sha256: 66f945ee88b3baceaf684abda1978a1966a82fec823f27d23e4bdcdf3fd1779c
Contents?: true
Size: 542 Bytes
Versions: 13
Compression:
Stored size: 542 Bytes
Contents
begin require 'will_paginate/collection' rescue LoadError raise(MeiliSearch::BadConfiguration, "MeiliSearch: Please add 'will_paginate' to your Gemfile to use will_paginate pagination backend") end module MeiliSearch module Rails module Pagination class WillPaginate def self.create(results, total_hits, options = {}) ::WillPaginate::Collection.create(options[:page], options[:per_page], total_hits) do |pager| pager.replace results end end end end end end
Version data entries
13 entries across 13 versions & 1 rubygems