diff --git a/InvenTree/stock/migrations/0064_auto_20210621_1724.py b/InvenTree/stock/migrations/0064_auto_20210621_1724.py index 361ad02c80..666de26189 100644 --- a/InvenTree/stock/migrations/0064_auto_20210621_1724.py +++ b/InvenTree/stock/migrations/0064_auto_20210621_1724.py @@ -43,7 +43,7 @@ def extract_purchase_price(apps, schema_editor): if lines.exists(): for line in lines: - if line.purchase_price is not None: + if getattr(line, 'purchase_price', None) is not None: # Copy pricing information across item.purchase_price = line.purchase_price