method

scope_for_association

Importance_0
v5.1.7 - Show latest stable - 0 notes - Class: ClassMethods
scope_for_association(scope = relation) public

No documentation

This method has no description. You can help the Ruby on Rails community by adding new notes.

Hide source
# File activerecord/lib/active_record/scoping/named.rb, line 32
        def scope_for_association(scope = relation) # :nodoc:
          current_scope = self.current_scope

          if current_scope && current_scope.empty_scope?
            scope
          else
            default_scoped(scope)
          end
        end
Register or log in to add new notes.