mirror of
https://github.com/heartcombo/devise.git
synced 2022-11-09 12:18:31 -05:00
Fix syntax error.
This commit is contained in:
parent
330cafd3d2
commit
30b35e3727
2 changed files with 8 additions and 4 deletions
|
@ -226,6 +226,12 @@ module Devise
|
||||||
yield self
|
yield self
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def self.ref(arg)
|
||||||
|
dependencies = ActiveSupport::Dependencies
|
||||||
|
dependencies.respond_to?(:reference) ?
|
||||||
|
dependencies.reference(arg) : dependencies.ref(arg)
|
||||||
|
end
|
||||||
|
|
||||||
def self.omniauth_providers
|
def self.omniauth_providers
|
||||||
omniauth_configs.keys
|
omniauth_configs.keys
|
||||||
end
|
end
|
||||||
|
@ -243,9 +249,7 @@ module Devise
|
||||||
|
|
||||||
# Set the mailer reference object to access the mailer.
|
# Set the mailer reference object to access the mailer.
|
||||||
def self.mailer=(class_name)
|
def self.mailer=(class_name)
|
||||||
@@mailer_ref = ActiveSupport::Dependencies.respond_to?(:reference)
|
@@mailer_ref = ref(class_name)
|
||||||
? ActiveSupport::Dependencies.reference(class_name)
|
|
||||||
: ActiveSupport::Dependencies.ref(class_name)
|
|
||||||
end
|
end
|
||||||
self.mailer = "Devise::Mailer"
|
self.mailer = "Devise::Mailer"
|
||||||
|
|
||||||
|
|
|
@ -50,7 +50,7 @@ module Devise
|
||||||
@singular = (options[:singular] || @scoped_path.tr('/', '_').singularize).to_sym
|
@singular = (options[:singular] || @scoped_path.tr('/', '_').singularize).to_sym
|
||||||
|
|
||||||
@class_name = (options[:class_name] || name.to_s.classify).to_s
|
@class_name = (options[:class_name] || name.to_s.classify).to_s
|
||||||
@ref = ActiveSupport::Dependencies.ref(@class_name)
|
@ref = Devise.ref(@class_name)
|
||||||
|
|
||||||
@path = (options[:path] || name).to_s
|
@path = (options[:path] || name).to_s
|
||||||
@path_prefix = options[:path_prefix]
|
@path_prefix = options[:path_prefix]
|
||||||
|
|
Loading…
Reference in a new issue