mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-01-29 21:17:17 +00:00
Use .find instead of .select().first
This commit is contained in:
@@ -6,7 +6,7 @@ class PendingPayments
|
||||
end
|
||||
|
||||
def payment_object
|
||||
@order.payments.select{ |payment| payment if payment.state == 'checkout' }.first
|
||||
@order.payments.find{ |payment| payment.state == 'checkout' }
|
||||
end
|
||||
|
||||
def can_be_captured?
|
||||
|
||||
Reference in New Issue
Block a user