mirror of
https://github.com/heartcombo/devise.git
synced 2022-11-09 12:18:31 -05:00
Load Devise ORM after initialization.
This commit is contained in:
parent
f6cc219210
commit
fdf06861b0
2 changed files with 4 additions and 2 deletions
|
@ -8,5 +8,9 @@ module Devise
|
|||
config.middleware.use Warden::Manager do |config|
|
||||
Devise.configure_warden(config)
|
||||
end
|
||||
|
||||
config.after_initialize do
|
||||
require "devise/orm/#{Devise.orm}"
|
||||
end
|
||||
end
|
||||
end
|
|
@ -3,8 +3,6 @@ module ActionDispatch::Routing
|
|||
# Ensure Devise modules are included only after loading routes, because we
|
||||
# need devise_for mappings already declared to create magic filters and
|
||||
# helpers.
|
||||
#
|
||||
# TODO Hook into initializers workflow
|
||||
def finalize_with_devise!
|
||||
finalize_without_devise!
|
||||
return if Devise.mappings.empty?
|
||||
|
|
Loading…
Add table
Reference in a new issue