Sha256: 7335102921100471c8e16e33534142dfc6374b698b5f4a6285d54268327357e3

Contents?: true

Size: 763 Bytes

Versions: 3

Compression:

Stored size: 763 Bytes

Contents

require 'rails/railtie'

module DeviseOnesignal
    class Railtie < Rails::Railtie

        initializer 'devise-onesignal.initialize' do
            abort 'Set your OneSignal app id in `config/initializers/devise-onesignal.rb`' if DeviseOnesignal.configuration && ( DeviseOnesignal.configuration.app_id.nil? || DeviseOnesignal.configuration.app_id == '' )
            ActiveSupport.on_load :action_controller do
                include DeviseOnesignal::DeviceConcern
            end
            ActiveSupport.on_load :action_view do
                include DeviseOnesignal::DeviceHelper
            end
            ActiveSupport.on_load :active_record do
                include DeviseOnesignal::Owner
            end
        end

    end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
devise-onesignal-4.0.1 lib/devise-onesignal/railtie.rb
devise-onesignal-4.0.0 lib/devise-onesignal/railtie.rb
devise-onesignal-3.2.0 lib/devise-onesignal/railtie.rb