Skip to content

Commit

Permalink
Deprecate Order#shipment as split_shipments makes it less relevant
Browse files Browse the repository at this point in the history
  • Loading branch information
GeekOnCoffee committed May 30, 2013
1 parent 375f044 commit 5a62d40
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions core/app/models/spree/order.rb
Original file line number Diff line number Diff line change
Expand Up @@ -305,9 +305,8 @@ def generate_order_number
self.number
end

# TODO should be deprecated by split shipments
# convenience method since many stores will not allow user to create multiple shipments
def shipment
ActiveSupport::Deprecation.warn("[SPREE] Spree::Order#shipment is typically incorrect due to multiple shipments and will be deprecated in Spree 2.1, please process Spree::Order#shipments instead.")
@shipment ||= shipments.last
end

Expand Down

0 comments on commit 5a62d40

Please sign in to comment.