diff options
author | Filipp Lepalaan <f@230.to> | 2013-07-02 01:18:34 +0300 |
---|---|---|
committer | Filipp Lepalaan <f@230.to> | 2013-07-02 01:18:34 +0300 |
commit | 391949c68afedfe5a51675d614d7cde39c7313e1 (patch) | |
tree | cedde3c09f3641a0ffa903813f86f58a34508be0 /gsxws/products.py | |
parent | 1cbe1dbf66437a6f464a77dd0c2edc447d6204c3 (diff) | |
download | py-gsxws-391949c68afedfe5a51675d614d7cde39c7313e1.tar.gz py-gsxws-391949c68afedfe5a51675d614d7cde39c7313e1.tar.bz2 py-gsxws-391949c68afedfe5a51675d614d7cde39c7313e1.zip |
Initialize parts list in Product.warranty()
Diffstat (limited to 'gsxws/products.py')
-rw-r--r-- | gsxws/products.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/gsxws/products.py b/gsxws/products.py index dc77dc2..0de6601 100644 --- a/gsxws/products.py +++ b/gsxws/products.py @@ -13,7 +13,7 @@ from core import GsxObject, GsxError def models(): """ >>> models() # doctest: +ELLIPSIS - {'MAC_ACC': {'models': ['AirPort Card', ... + {'IPODCLASSIC': {'models': ['iPod 5th Generation (Late 2006)', ... """ import os import yaml @@ -58,6 +58,8 @@ class Product(GsxObject): if not hasattr(self, "serialNumber"): self.activation() + self.parts = [] + try: self.partNumbers = [] for k, v in parts: |