You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: order_cycle.rb
    path of file: ./repos/openfoodnetwork/app/models
    
    the code of the file until where you have to start completion: # frozen_string_literal: true

require 'open_food_network/scope_variant_to_hub'

class OrderCycle
    
  def distributor_shipping_methods
    if simple? || selected_distributor_shipping_methods.none?
      attachable_distributor_shipping_methods
    else
      attachable_distributor_shipping_methods.where(
        "distributors_shipping_methods.id IN (?) OR distributor_id NOT IN (?)",
        selected_distributor_shipping_methods.map(&:id),
        selected_distributor_shipping_methods.map(&:distributor_id)
      )
    end