Method: DynamicDefaultScoping::Relation#method_missing

Defined in:
lib/dynamic_default_scoping.rb

#method_missing(method, *args, &block) ⇒ Object (protected)



61
62
63
64
65
66
67
# File 'lib/dynamic_default_scoping.rb', line 61

def method_missing method, *args, &block
  if @klass.scopes[method].present?
    merge @klass.unscoped { @klass.send method, *args, &block }
  else
    super
  end
end