mirror of
https://github.com/nophead/NopSCADlib.git
synced 2025-01-16 21:18:15 +01:00
Fixed Python error when top level assembly is empty.
This commit is contained in:
parent
baaa85ffed
commit
f3bfbbfcf2
@ -77,7 +77,7 @@ def bom_to_assemblies(bom_dir, bounds_map):
|
||||
#
|
||||
if flat_bom:
|
||||
ass = flat_bom[-1]
|
||||
if len(ass["assemblies"]) < 2 and not ass["vitamins"] and not ass["printed"] and not ass["routed"]:
|
||||
if len(ass["assemblies"]) == 1 and not ass["vitamins"] and not ass["printed"] and not ass["routed"]:
|
||||
flat_bom = flat_bom[:-1]
|
||||
return [assembly["name"] for assembly in flat_bom]
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user