Skip to content

Commit

Permalink
names should not be able to be null
Browse files Browse the repository at this point in the history
  • Loading branch information
madhephaestus committed Oct 27, 2024
1 parent 8ada780 commit 380c6fb
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 6 deletions.
10 changes: 5 additions & 5 deletions box.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 2 additions & 0 deletions src/main/java/eu/mihosoft/vrl/v3d/CSG.java
Original file line number Diff line number Diff line change
Expand Up @@ -2413,6 +2413,8 @@ public String getName() {
}

public CSG setName(String name) {
if(name==null)
throw new NullPointerException();
this.name = name;
return this;
}
Expand Down
4 changes: 3 additions & 1 deletion src/test/java/eu/mihosoft/vrl/v3d/SVGLoadTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,9 @@ private ArrayList<CSG> run(SVGLoad s) {
// extrudeLayerToCSG.setColor(Color.web(SVGExporter.colorNames.get(i)));
for(String key:extrudeLayerToCSG.keySet()) {
//System.out.println("Adding layer: "+key);
polys.add(CSG.unionAll(extrudeLayerToCSG.get(key)));
ArrayList<CSG> csgs = extrudeLayerToCSG.get(key);
if(csgs.size()>0)
polys.add(CSG.unionAll(csgs));
// for(CSG c:extrudeLayerToCSG.get(key)) {
// polys.add(c);
// }
Expand Down

0 comments on commit 380c6fb

Please sign in to comment.