mirror of
https://github.com/heartcombo/devise.git
synced 2022-11-09 12:18:31 -05:00
Add latest commities entries to CHANGELOG.
This commit is contained in:
parent
0c7c762c16
commit
345bf159e2
4 changed files with 25 additions and 15 deletions
|
@ -1,11 +1,13 @@
|
|||
* deprecation
|
||||
* devise :all is deprecated
|
||||
* :success and :failure flash messages are now :notice and :alert
|
||||
|
||||
* enhancements
|
||||
* Added devise lockable (by github/mhfs)
|
||||
* Added devise lockable (by github.com/mhfs)
|
||||
* Warden 0.9.0 compatibility
|
||||
* Mongomapper 0.6.10 compatibility
|
||||
* :success and :failure flash messages are now :notice and :alert
|
||||
* Added Devise.add_module as hooks for extensions (by github.com/grimen)
|
||||
* Ruby 1.9.1 compatibility (by github.com/grimen)
|
||||
|
||||
* bug fix
|
||||
* Accept path prefix not starting with slash
|
||||
|
@ -14,10 +16,10 @@
|
|||
== 0.8.2
|
||||
|
||||
* enhancements
|
||||
* Allow Devise.mailer_sender to be a proc (by github/grimen)
|
||||
* Allow Devise.mailer_sender to be a proc (by github.com/grimen)
|
||||
|
||||
* bug fix
|
||||
* Fix bug with passenger, update is required to anyone deploying on passenger (by github/dvdpalm)
|
||||
* Fix bug with passenger, update is required to anyone deploying on passenger (by github.com/dvdpalm)
|
||||
|
||||
== 0.8.1
|
||||
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
module Devise
|
||||
autoload :FailureApp, 'devise/failure_app'
|
||||
autoload :Mapping, 'devise/mapping'
|
||||
autoload :Schema, 'devise/schema'
|
||||
autoload :TestHelpers, 'devise/test_helpers'
|
||||
|
||||
|
@ -199,18 +198,22 @@ module Devise
|
|||
# Devise.add_module(:party_module, :model => 'party_module/model')
|
||||
#
|
||||
def add_module(module_name, options = {})
|
||||
Devise::ALL.unshift module_name unless Devise::ALL.include?(module_name)
|
||||
Devise::ALL.unshift module_name unless Devise::ALL.include?(module_name)
|
||||
Devise::STRATEGIES.unshift module_name if options[:strategy] && !Devise::STRATEGIES.include?(module_name)
|
||||
if options[:controller].present?
|
||||
|
||||
if options[:controller]
|
||||
controller = options[:controller].to_sym
|
||||
Devise::CONTROLLERS[controller] ||= []
|
||||
Devise::CONTROLLERS[controller].unshift module_name unless Devise::CONTROLLERS[controller].include?(module_name)
|
||||
end
|
||||
if options[:model].present?
|
||||
|
||||
if options[:model]
|
||||
Devise::Models.module_eval do
|
||||
autoload :"#{module_name.to_s.classify}", options[:model]
|
||||
end
|
||||
end
|
||||
|
||||
Devise::Mapping.register module_name
|
||||
end
|
||||
end
|
||||
end
|
||||
|
@ -222,4 +225,5 @@ rescue
|
|||
require 'warden'
|
||||
end
|
||||
|
||||
require 'devise/mapping'
|
||||
require 'devise/rails'
|
|
@ -1,6 +1,6 @@
|
|||
module Devise
|
||||
module Controllers
|
||||
# Common actions shared between Devie controllers
|
||||
# Common actions shared between Devise controllers
|
||||
module Common #:nodoc:
|
||||
# GET /resource/controller/new
|
||||
def new
|
||||
|
|
|
@ -109,6 +109,7 @@ module Devise
|
|||
end
|
||||
end
|
||||
|
||||
|
||||
# Create magic predicates for verifying what module is activated by this map.
|
||||
# Example:
|
||||
#
|
||||
|
@ -116,13 +117,16 @@ module Devise
|
|||
# self.for.include?(:confirmable)
|
||||
# end
|
||||
#
|
||||
ALL.each do |m|
|
||||
class_eval <<-METHOD, __FILE__, __LINE__
|
||||
def #{m}?
|
||||
self.for.include?(:#{m})
|
||||
end
|
||||
METHOD
|
||||
def self.register(*modules)
|
||||
modules.each do |m|
|
||||
class_eval <<-METHOD, __FILE__, __LINE__
|
||||
def #{m}?
|
||||
self.for.include?(:#{m})
|
||||
end
|
||||
METHOD
|
||||
end
|
||||
end
|
||||
Devise::Mapping.register *ALL
|
||||
|
||||
private
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue