From 2a1b371974c05ccdb5d805955fb49333413e61fb Mon Sep 17 00:00:00 2001 From: "Veronica K. B. Olsen" Date: Sun, 19 May 2019 00:20:29 +0200 Subject: [PATCH] Adding a bug trap too ... --- nw/project/project.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/nw/project/project.py b/nw/project/project.py index 9ee97bbd..a2462d4d 100644 --- a/nw/project/project.py +++ b/nw/project/project.py @@ -383,7 +383,10 @@ class NWProject(): n += 1 if n > 10000: return # Just in case - if tItem.parHandle is None: + if tItem is None: + # Technically a bug since treeOrder is built from the same data as projTree + continue + elif tItem.parHandle is None: # Item is a root, or already been identified as an orphaned item sentItems.append(tHandle) yield tItem