Flowdock
method

where_unscoping

Importance_0
v4.0.2 - Show latest stable - 0 notes - Class: ActiveRecord::QueryMethods
where_unscoping(target_value) private

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/relation/query_methods.rb, line 847
    def where_unscoping(target_value)
      target_value_sym = target_value.to_sym

      where_values.reject! do |rel|
        case rel
        when Arel::Nodes::In, Arel::Nodes::Equality
          subrelation = (rel.left.kind_of?(Arel::Attributes::Attribute) ? rel.left : rel.right)
          subrelation.name.to_sym == target_value_sym
        else
          raise "unscope(where: #{target_value.inspect}) failed: unscoping #{rel.class} is unimplemented."
        end
      end
    end
Register or log in to add new notes.