From 54d85328288b2e0ba21ee1b8e40fba2d96cdcf8f Mon Sep 17 00:00:00 2001 From: Benjamin Dauvergne Date: Wed, 21 Aug 2019 20:23:52 +0200 Subject: [PATCH] wf/wscall: test if response is not None (#35527) --- wcs/wf/wscall.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wcs/wf/wscall.py b/wcs/wf/wscall.py index ede4c98ae..2bc02df61 100644 --- a/wcs/wf/wscall.py +++ b/wcs/wf/wscall.py @@ -399,8 +399,8 @@ class WebserviceCallStatusItem(WorkflowStatusItem): if exc_info: summary = traceback.format_exception_only(exc_info[0], exc_info[1])[-1] else: - summary = '' - if response: + summary = '' + if response is not None: summary = '%s %s' % (response.status_code, response.reason) try: raise Exception(summary)