Fix some rubocop issues

This commit is contained in:
luisramos0
2019-11-18 15:02:21 +00:00
parent 5cf50f0adf
commit 0bec492208
2 changed files with 5 additions and 2 deletions

View File

@@ -14,7 +14,8 @@ class Api::Admin::ForOrderCycle::SuppliedProductSerializer < ActiveModel::Serial
end
def variants
variants = if order_cycle.present? && order_cycle.prefers_product_selection_from_coordinator_inventory_only?
variants = if order_cycle.present? &&
order_cycle.prefers_product_selection_from_coordinator_inventory_only?
object.variants.visible_for(order_cycle.coordinator)
else
object.variants

View File

@@ -41,7 +41,9 @@ class ExchangeProductsRenderer
@incoming_exchanges_variants = []
visible_incoming_exchanges.each do |incoming_exchange|
@incoming_exchanges_variants.push(
*incoming_exchange.variants.merge(visible_incoming_variants(incoming_exchange.sender)).map(&:id).to_a
*incoming_exchange.variants.merge(
visible_incoming_variants(incoming_exchange.sender)
).map(&:id).to_a
)
end
@incoming_exchanges_variants