Fix rubocop suggestions

This commit is contained in:
oguzhankoral
2023-03-08 23:35:26 +03:00
parent 3de3128a2a
commit 825b7b98d7
2 changed files with 5 additions and 4 deletions
@@ -70,8 +70,8 @@ module SpeckleConnector
indices = faces.shift(num_pts)
native_mesh.add_polygon(indices.map { |index| points[index] })
end
state, materials = Other::RenderMaterial.to_native(state, mesh['renderMaterial'],
layer, entities, &convert_to_native)
state, _materials = Other::RenderMaterial.to_native(state, mesh['renderMaterial'],
layer, entities, &convert_to_native)
# Find and assign material if exist
unless mesh['renderMaterial'].nil?
material_name = mesh['renderMaterial']['name'] || mesh['renderMaterial']['id']
@@ -150,9 +150,10 @@ module SpeckleConnector
# without instances
find_and_erase_existing_instance(definition, block['id'], block['applicationId'])
puts("Failed to create instance for speckle block instance #{block['id']}") if instance.nil?
# Transform already applied to instance unless is group
instance.transformation = transform if is_group
state, materials = Other::RenderMaterial.to_native(state, block['renderMaterial'],
layer, entities, &convert_to_native)
state, _materials = Other::RenderMaterial.to_native(state, block['renderMaterial'],
layer, entities, &convert_to_native)
# Retrieve material from state
unless block['renderMaterial'].nil?