Skip to content

Commit

Permalink
replace for with foreach (junit-team#1560)
Browse files Browse the repository at this point in the history
  • Loading branch information
renuka-fernando authored and kcooney committed Oct 10, 2018
1 parent 0deb1b9 commit 29b1dfb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/java/org/junit/rules/TemporaryFolder.java
Original file line number Diff line number Diff line change
Expand Up @@ -200,8 +200,8 @@ public File newFolder(String... paths) throws IOException {
File relativePath = null;
File file = root;
boolean lastMkdirsCallSuccessful = true;
for (int i = 0; i < paths.length; i++) {
relativePath = new File(relativePath, paths[i]);
for (String path : paths) {
relativePath = new File(relativePath, path);
file = new File(root, relativePath.getPath());

lastMkdirsCallSuccessful = file.mkdirs();
Expand Down

0 comments on commit 29b1dfb

Please sign in to comment.