File: init.rb

package info (click to toggle)
ruby-will-paginate 4.0.1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 440 kB
  • sloc: ruby: 2,734; sh: 33; makefile: 4
file content (18 lines) | stat: -rw-r--r-- 471 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
require 'will_paginate'

# This is all duplication of what Railtie does, but is necessary because
# the initializer defined by the Railtie won't ever run when loaded as plugin.

if defined? ActiveRecord::Base
  require 'will_paginate/active_record'
end

if defined? ActionController::Base
  WillPaginate::Railtie.setup_actioncontroller
end

if defined? ActionView::Base
  require 'will_paginate/view_helpers/action_view'
end

WillPaginate::Railtie.add_locale_path config