diff options
author | Filipp Lepalaan <filipp@mac.com> | 2015-10-14 22:05:33 +0300 |
---|---|---|
committer | Filipp Lepalaan <filipp@mac.com> | 2015-10-14 22:05:33 +0300 |
commit | 1bb52b1417a79758e27ba4a3c71ba0f1d4cbbf8b (patch) | |
tree | 93d3d85b5937dfef8a40552b752688e11e0443f6 | |
parent | 3420f74425c8e8247bef4a916bc053f1ed95df07 (diff) | |
download | py-gsxws-1bb52b1417a79758e27ba4a3c71ba0f1d4cbbf8b.tar.gz py-gsxws-1bb52b1417a79758e27ba4a3c71ba0f1d4cbbf8b.tar.bz2 py-gsxws-1bb52b1417a79758e27ba4a3c71ba0f1d4cbbf8b.zip |
Raise GsxError on empty Symptom/Issue search result
-rw-r--r-- | gsxws/repairs.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/gsxws/repairs.py b/gsxws/repairs.py index 989c94d..e34219f 100644 --- a/gsxws/repairs.py +++ b/gsxws/repairs.py @@ -59,6 +59,10 @@ class SymptomIssue(GsxObject): "ReportedSymptomIssueResponse") r = self._req.objects.reportedSymptomIssueResponse + # This may sometimes come back empty... + if r is None: + raise GsxError('Symptom/Issue code search failed') + if r.symptoms is not None: for s in r.symptoms: result.append((s.reportedSymptomCode, s.reportedSymptomDesc,)) |