mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-17 14:02:27 +00:00
Fix error due to trying to patch non-existent file
This commit is contained in:
@@ -40,6 +40,11 @@ class ExecuteIfcPatch(bpy.types.Operator):
|
|||||||
bl_label = "Execute IFCPatch"
|
bl_label = "Execute IFCPatch"
|
||||||
file_format: bpy.props.StringProperty()
|
file_format: bpy.props.StringProperty()
|
||||||
|
|
||||||
|
@classmethod
|
||||||
|
def poll(cls, context):
|
||||||
|
input_file = context.scene.BIMPatchProperties.ifc_patch_input
|
||||||
|
return os.path.isfile(input_file) and "ifc" in os.path.splitext(input_file)[1]
|
||||||
|
|
||||||
def execute(self, context):
|
def execute(self, context):
|
||||||
import ifcpatch
|
import ifcpatch
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user