Skip to content

Commit

Permalink
small code fix
Browse files Browse the repository at this point in the history
  • Loading branch information
joamag committed May 31, 2016
1 parent 5bd507c commit 93c31bb
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/budy/models/product.py
Expand Up @@ -38,7 +38,6 @@
""" The license for the module """

import json
import types
import commons

import appier
Expand Down Expand Up @@ -389,7 +388,7 @@ def pre_save(self):
base.BudyBase.pre_save(self)
self._update_search_description()
if not self.measurements: return
self.quantity_hand = sum(measurement.quantity for measurement in self.measurements)
self.quantity_hand = sum(measurement.quantity_hand for measurement in self.measurements)
self.price = max(measurement.price for measurement in self.measurements)

@appier.operation(name = "Update Search Description")
Expand Down

0 comments on commit 93c31bb

Please sign in to comment.