mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-01-30 21:27:17 +00:00
Use Arel.sql to curcunvent security restriction on rails 6.1
This commit is contained in:
@@ -31,7 +31,9 @@ class ProductsRenderer
|
||||
return unless order_cycle
|
||||
|
||||
@products ||= begin
|
||||
results = distributed_products.products_relation.order(taxon_order)
|
||||
results = distributed_products.
|
||||
products_relation.
|
||||
order(Arel.sql(taxon_order))
|
||||
|
||||
filter_and_paginate(results).
|
||||
each { |product| product_scoper.scope(product) } # Scope results with variant_overrides
|
||||
|
||||
Reference in New Issue
Block a user