Remove dead code related to multiple product taxons

This commit is contained in:
Matt-Yorkley
2023-08-09 11:33:05 +01:00
committed by Gaetan Craig-Riou
parent fb09a7f1e6
commit 02abe5cc06

View File

@@ -46,18 +46,12 @@ module Sets
# variant.update( { price: xx.x } )
#
def update_product_attributes(attributes)
split_taxon_ids!(attributes)
product = find_model(@collection, attributes[:id])
return if product.nil?
update_product(product, attributes)
end
def split_taxon_ids!(attributes)
attributes[:taxon_ids] = attributes[:taxon_ids].split(',') if attributes[:taxon_ids].present?
end
def update_product(product, attributes)
return false unless update_product_only_attributes(product, attributes)