Skip to content

Commit

Permalink
new operational error
Browse files Browse the repository at this point in the history
  • Loading branch information
joamag committed Mar 20, 2016
1 parent b14c771 commit 078f735
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/budy/models/bundle.py
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,10 @@ def add_product_s(

_line = None

if not product: raise appier.OperationalError(
message = "No product defined"
)

for line in self.lines:
is_same = line.product.id == product.id
is_same &= line.size == size
Expand Down

0 comments on commit 078f735

Please sign in to comment.