Module: CanTango::Api::User::All

Defined in:
lib/cantango/api/user.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.included(base) ⇒ Object



7
8
9
10
11
# File 'lib/cantango/api/user.rb', line 7

def self.included base
  [:Ability, :Can, :Scope, :Session].each do |api|
    base.send :include, clazz(api)
  end
end

Instance Method Details

#clazz(api) ⇒ Object



13
14
15
# File 'lib/cantango/api/user.rb', line 13

def clazz api
  ("CanTango::Api::User::" << api.to_s.camelize).constantize
end