From a42746264684fcdfc5f4854a17a5383c2fb89fd1 Mon Sep 17 00:00:00 2001 From: Long <931924+htlcnn@users.noreply.github.com> Date: Sat, 31 Jul 2021 09:39:05 +0700 Subject: [PATCH] GlobalId is string (#1615) --- src/blenderbim/blenderbim/bim/module/diff/operator.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/blenderbim/blenderbim/bim/module/diff/operator.py b/src/blenderbim/blenderbim/bim/module/diff/operator.py index e932629ecc..6054df59b8 100644 --- a/src/blenderbim/blenderbim/bim/module/diff/operator.py +++ b/src/blenderbim/blenderbim/bim/module/diff/operator.py @@ -36,11 +36,11 @@ class VisualiseDiff(bpy.types.Operator): global_id = ifc_file.by_id(obj.BIMObjectProperties.ifc_definition_id).GlobalId if not global_id: continue - if global_id.string_value in diff["deleted"]: + if global_id in diff["deleted"]: obj.color = (1.0, 0.0, 0.0, 0.2) - elif global_id.string_value in diff["added"]: + elif global_id in diff["added"]: obj.color = (0.0, 1.0, 0.0, 0.2) - elif global_id.string_value in diff["changed"]: + elif global_id in diff["changed"]: obj.color = (0.0, 0.0, 1.0, 0.2) area = next(area for area in context.screen.areas if area.type == "VIEW_3D") area.spaces[0].shading.color_type = "OBJECT"