From 7fea311d601a59027a10bfcd6b2628e1e20e6b99 Mon Sep 17 00:00:00 2001 From: Julien ANNE Date: Thu, 23 Mar 2023 14:55:06 +0100 Subject: [PATCH] Authorize uuid for update_positions on ResourceController --- backend/app/controllers/spree/admin/resource_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/app/controllers/spree/admin/resource_controller.rb b/backend/app/controllers/spree/admin/resource_controller.rb index 5a126e71c8c..0a91f010174 100644 --- a/backend/app/controllers/spree/admin/resource_controller.rb +++ b/backend/app/controllers/spree/admin/resource_controller.rb @@ -82,7 +82,7 @@ def update_positions records = model_class.where(id: positions.keys).to_a positions.each do |id, index| - records.find { |r| r.id == id.to_i }&.set_list_position(index) + records.find { |r| r.id.to_s == id }&.set_list_position(index) end end