mirror of
				https://github.com/SoftFever/OrcaSlicer.git
				synced 2025-10-30 20:21:12 -06:00 
			
		
		
		
	Merge pull request #407 from beanz/simplify-check-manifoldness
Remove grep that is effectively repeated.
This commit is contained in:
		
						commit
						2e3c8241e4
					
				
					 1 changed files with 4 additions and 3 deletions
				
			
		|  | @ -127,9 +127,10 @@ sub clean { | ||||||
| sub check_manifoldness { | sub check_manifoldness { | ||||||
|     my $self = shift; |     my $self = shift; | ||||||
|      |      | ||||||
|     # look for edges not connected to exactly two facets |     # look for any edges not connected to exactly two facets | ||||||
|     if (grep { @$_ != 2 } @{$self->edges_facets}) { |     my ($first_bad_edge_id) = | ||||||
|         my ($first_bad_edge_id) = grep { @{ $self->edges_facets->[$_] } != 2 } 0..$#{$self->edges_facets}; |         grep { @{ $self->edges_facets->[$_] } != 2 } 0..$#{$self->edges_facets}; | ||||||
|  |     if (defined $first_bad_edge_id) { | ||||||
|         warn sprintf "Warning: The input file is not manifold near edge %f-%f. " |         warn sprintf "Warning: The input file is not manifold near edge %f-%f. " | ||||||
|             . "You might want to check the resulting G-code before printing.\n", |             . "You might want to check the resulting G-code before printing.\n", | ||||||
|             @{$self->edges->[$first_bad_edge_id]}; |             @{$self->edges->[$first_bad_edge_id]}; | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Alessandro Ranellucci
						Alessandro Ranellucci