mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-17 22:11:36 +00:00
Fix bug when an entity doesn't have any predefined type to fetch in the docs
This commit is contained in:
@@ -125,7 +125,10 @@ def get_ifc_entity_doc_url(ifc_entity):
|
|||||||
def get_predefined_type_description(entity, predefined_type):
|
def get_predefined_type_description(entity, predefined_type):
|
||||||
schema = tool.Ifc.get_schema()
|
schema = tool.Ifc.get_schema()
|
||||||
if schema is not None:
|
if schema is not None:
|
||||||
return get_predefined_type_doc(schema, entity, predefined_type)
|
try:
|
||||||
|
return get_predefined_type_doc(schema, entity, predefined_type)
|
||||||
|
except KeyError: # This entity doesn't have any predefined types
|
||||||
|
return ""
|
||||||
|
|
||||||
|
|
||||||
HARDCODED_ATTRIBUTE_DESCRIPTIONS = {
|
HARDCODED_ATTRIBUTE_DESCRIPTIONS = {
|
||||||
|
|||||||
Reference in New Issue
Block a user