Fix pnf package delete logic 42/70542/1
authorfujinhua <fu.jinhua@zte.com.cn>
Tue, 16 Oct 2018 08:38:54 +0000 (16:38 +0800)
committerfujinhua <fu.jinhua@zte.com.cn>
Tue, 16 Oct 2018 08:38:54 +0000 (16:38 +0800)
Change-Id: If3a0d5ef87812f8f898cd832aceba70d4fd7f8c9
Issue-ID: VFC-1151
Signed-off-by: fujinhua <fu.jinhua@zte.com.cn>
catalog/packages/biz/pnf_descriptor.py

index fe77344..78b55b0 100644 (file)
@@ -96,6 +96,8 @@ class PnfDescriptor(object):
             nsd_model = None
             if ns_pkg.nsdModel:
                 nsd_model = json.JSONDecoder().decode(ns_pkg.nsdModel)
+            if not nsd_model:
+                continue
             pnf_info_ids = []
             for pnf in nsd_model['pnfs']:
                 pnfd_id = pnf["properties"]["id"]