File: engine.rb

package info (click to toggle)
ruby-noticed 3.0.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 324 kB
  • sloc: ruby: 1,186; makefile: 4
file content (15 lines) | stat: -rw-r--r-- 384 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
module Noticed
  class Engine < ::Rails::Engine
    isolate_namespace Noticed

    initializer "noticed.deprecator" do |app|
      app.deprecators[:noticed] = Noticed.deprecator if app.respond_to?(:deprecators)
    end

    initializer "noticed.has_notifications" do
      ActiveSupport.on_load(:active_record) do
        include Noticed::HasNotifications
      end
    end
  end
end