app/services/solidus_subscriptions/line_item_builder.rb
def spree_line_items
      line_items = subscription_line_items.map do |subscription_line_item|
        variant = subscription_line_item.subscribable

        next unless variant.can_supply?(subscription_line_item.quantity)

        ::Spree::LineItem.new(variant: variant, quantity: subscription_line_item.quantity)
      end

      # Either all line items for an installment are fulfilled or none are
      line_items.all? ? line_items : []
    end
# Get a new (unpersisted) Spree::LineItem which matches the details of
# :subscription_line_item
#
# @return [Array<Spree::LineItem>]
Get a new (unpersisted) Spree::LineItem which matches the details of
:subscription_line_item
Get a new ( unpersisted ) Spree :: LineItem which matches the details of : subscription_line_item
def spree_line_items
      line_items = subscription_line_items.map do |subscription_line_item|
        variant = subscription_line_item.subscribable
        next unless variant.can_supply?(subscription_line_item.quantity)
        ::Spree::LineItem.new(variant: variant, quantity: subscription_line_item.quantity)
      end
      line_items.all? ? line_items : []
    end
def spree_line_items line_items = subscription_line_items . map do | subscription_line_item | variant = subscription_line_item . subscribable next unless variant . can_supply? ( subscription_line_item . quantity ) :: Spree :: LineItem . new ( variant : variant , quantity : subscription_line_item . quantity ) end line_items . all? ? line_items : [ ] end
Get a new (unpersisted) Spree::LineItem which matches the details of
:subscription_line_item
Get a new ( unpersisted ) Spree :: LineItem which matches the details of : subscription_line_item
# Either all line items for an installment are fulfilled or none are
None
Array<Spree::LineItem>