forked from youen/assembly_handbook
Fixed error when a document has multiple "main" objects
This commit is contained in:
parent
cbf1d1b275
commit
f92482eb46
@ -800,9 +800,9 @@ class TechDrawExtensions:
|
|||||||
if obj.TypeId == 'TechDraw::DrawPage':
|
if obj.TypeId == 'TechDraw::DrawPage':
|
||||||
self.onPageLoaded(obj)
|
self.onPageLoaded(obj)
|
||||||
|
|
||||||
main_part = doc.getObjectsByLabel(doc.Name)
|
main_parts = doc.getObjectsByLabel(doc.Name)
|
||||||
if len(main_part) == 1:
|
if len(main_parts) == 1:
|
||||||
main_part = main_part[0]
|
main_part = main_parts[0]
|
||||||
except:
|
except:
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user