Skip to content

Commit

Permalink
Upgrade to rewrite 6.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
jkschneider committed Nov 24, 2020
1 parent 6cc75c0 commit 1294ad7
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ public Collection<SourceFile> generate() {
"@ConfigurationProperties(\"" + String.join(".", commonPrefix) + "\")\n" +
"public class " + className + " {\n" +
"}\n";
Path parentDir = Paths.get(springBootApplication.getSourcePath()).getParent();
Path parentDir = Paths.get(springBootApplication.getSourcePath().toString()).getParent();
Path sourcePath;
if(parentDir == null) {
sourcePath = Paths.get(className + ".java");
Expand All @@ -150,7 +150,7 @@ public Collection<SourceFile> generate() {
J.CompilationUnit cu = fillConfigurationPropertiesTypeAttribution(
jp.reset().parse(newClassText)
.get(0)
.withSourcePath(sourcePath.toString()));
.withSourcePath(sourcePath.toUri()));
generatedClasses.put(className, cu);
return cu;

Expand Down

0 comments on commit 1294ad7

Please sign in to comment.