Skip to content
Snippets Groups Projects
Commit fba8c3db authored by Campbell Barton's avatar Campbell Barton
Browse files

Fix export pc2 poll function

Assumed active object
parent 5a2c3d67
No related branches found
No related tags found
No related merge requests found
......@@ -153,7 +153,11 @@ class Export_pc2(bpy.types.Operator, ExportHelper):
@classmethod
def poll(cls, context):
return context.active_object.type in {'MESH', 'CURVE', 'SURFACE', 'FONT'}
obj = context.active_object
return (
obj is not None and
obj.type in {'MESH', 'CURVE', 'SURFACE', 'FONT'}
)
def execute(self, context):
start_time = time.time()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment