struct

CanCan::RawScope

Inherits Struct < Value < Object

A relation passed as rule conditions (the gem's can :read, Article, Article.where(...) scope form). Crystal cannot union Relation(T) over all models, so the query-facing parts are captured up front.

Constructors

new(rel : ActiveRecord::Relation)

Instance methods

==(other : RawScope) : Bool
blank?

The gem's catch-all test for scopes: where_values_hash.empty?.

empty?
fragments
where_values_hash