lib/bbq/devise.rb in bbq-0.0.4 vs lib/bbq/devise.rb in bbq-0.1.0
- old
+ new
@@ -3,9 +3,14 @@
module Bbq
module Devise
attr_accessor :devise_authentication_key, :email, :password, :scope
+ def self.included(klass)
+ require 'bbq/rails/routes'
+ klass.send(:include, Bbq::Rails::Routes)
+ end
+
def initialize_devise
@devise_initialized ||= begin
self.devise_authentication_key = ::Devise.authentication_keys.first
self.email = options[devise_authentication_key.to_sym] || Bbq::Devise.next_email
self.password = options[:password] || Bbq::Devise.next_password