lib/arel/algebra/relations/operations/order.rb in arel-0.3.1 vs lib/arel/algebra/relations/operations/order.rb in arel-0.3.2
- old
+ new
@@ -1,8 +1,9 @@
module Arel
class Order < Compound
attributes :relation, :orderings
- deriving :==
+ deriving :==
+ requires :ordering
def initialize(relation, *orderings, &block)
@relation = relation
@orderings = (orderings + arguments_from_block(relation, &block)) \
.collect { |o| o.bind(relation) }