Module: Jm81auth::Models::User
- Defined in:
- lib/jm81auth/models/user.rb
Defined Under Namespace
Modules: ClassMethods
Constant Summary collapse
- EMAIL_REGEX =
/.@./
Class Method Summary collapse
Class Method Details
.included(base) ⇒ Object
6 7 8 9 10 11 12 13 14 15 16 17 18 |
# File 'lib/jm81auth/models/user.rb', line 6 def self.included(base) base.extend ClassMethods base.class_eval do if respond_to? :has_many has_many :auth_methods has_many :auth_tokens else one_to_many :auth_methods one_to_many :auth_tokens end end end |