mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-03-22 05:18:51 +00:00
Handle OrderBalance comparison operators
These operators get used on the object returned by order_balance in a few places, and were not working correctly.
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
class OrderBalance
|
||||
delegate :zero?, :abs, :to_s, :to_f, :to_d, to: :amount
|
||||
delegate :zero?, :abs, :to_s, :to_f, :to_d, :<, :>, to: :amount
|
||||
|
||||
def initialize(order)
|
||||
@order = order
|
||||
|
||||
Reference in New Issue
Block a user