Skip to content

Commit 54ef0d7

Browse files
committed
Fix compilation issue following upstream change
1 parent 5bc947c commit 54ef0d7

File tree

2 files changed

+6
-8
lines changed

2 files changed

+6
-8
lines changed

src/main/java/org/openrewrite/java/migrate/UseJavaUtilBase64.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ public J visitMethodInvocation(J.MethodInvocation method, ExecutionContext ctx)
117117
// Note: The sun.misc.CharacterDecoder#decodeBuffer throws an IOException, whereas the java
118118
// Base64Decoder.decode does not throw a checked exception. If this recipe converts decode, we
119119
// may need to remove the catch or completely unwrap a try/catch.
120-
doAfterVisit(new UnnecessaryCatch(false).getVisitor());
120+
doAfterVisit(new UnnecessaryCatch(false, false).getVisitor());
121121
}
122122
return m;
123123
}

src/test/java/org/openrewrite/java/migrate/jakarta/JavaxInjectToJakartaInjectTest.java

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -53,13 +53,11 @@ void projectWithJavaxInject() {
5353
</dependencies>
5454
</project>
5555
""",
56-
spec -> spec.after(actual -> {
57-
assertThat(actual)
58-
.contains("<groupId>jakarta.inject</groupId>")
59-
.contains("<artifactId>jakarta.inject-api</artifactId>")
60-
.containsPattern("<version>[0-9]+\\.[0-9]+\\.[0-9]+</version>");
61-
return actual;
62-
})
56+
spec -> spec.after(actual -> assertThat(actual)
57+
.contains("<groupId>jakarta.inject</groupId>")
58+
.contains("<artifactId>jakarta.inject-api</artifactId>")
59+
.containsPattern("<version>[0-9]+\\.[0-9]+\\.[0-9]+</version>")
60+
.actual())
6361
)
6462
);
6563
}

0 commit comments

Comments
 (0)