From 5a91490d90cfbbe447454c6f0ca83ff4c9f28283 Mon Sep 17 00:00:00 2001 From: Slawomir Jaranowski Date: Mon, 30 Mar 2026 22:04:16 +0200 Subject: [PATCH] Use getOutputPath instead of deprecated getOutputName --- .../apache/maven/reporting/AbstractMavenReport.java | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/main/java/org/apache/maven/reporting/AbstractMavenReport.java b/src/main/java/org/apache/maven/reporting/AbstractMavenReport.java index 8e1e699..c2dd8b5 100644 --- a/src/main/java/org/apache/maven/reporting/AbstractMavenReport.java +++ b/src/main/java/org/apache/maven/reporting/AbstractMavenReport.java @@ -217,9 +217,9 @@ public final void execute() throws MojoExecutionException { private void reportToMarkup() throws MojoExecutionException { Path relativeOutput = getProject().getBasedir().toPath().relativize(new File(getOutputDirectory()).toPath()); if (isExternalReport()) { - getLog().info("Rendering external report to " + relativeOutput.resolve(getOutputName())); + getLog().info("Rendering external report to " + relativeOutput.resolve(getOutputPath())); } else { - String filename = getOutputName() + '.' + outputFormat; + String filename = getOutputPath() + '.' + outputFormat; getLog().info("Rendering report as " + outputFormat + " markup to " + relativeOutput.resolve(filename)); try { @@ -256,11 +256,11 @@ public Sink createSink(File file, String filename) throws IOException { } private void reportToSite() throws MojoExecutionException { - String filename = getOutputName() + ".html"; + String filename = getOutputPath() + ".html"; Path relativeOutput = getProject().getBasedir().toPath().relativize(new File(getOutputDirectory()).toPath()); if (isExternalReport()) { - getLog().info("Rendering external report to " + relativeOutput.resolve(getOutputName())); + getLog().info("Rendering external report to " + relativeOutput.resolve(getOutputPath())); } else { getLog().info("Rendering report to " + relativeOutput.resolve(filename)); } @@ -277,7 +277,7 @@ private void reportToSite() throws MojoExecutionException { String reportMojoInfo = mojoExecution.getPlugin().getId() + ":" + mojoExecution.getGoal(); DocumentRenderingContext docRenderingContext = - new DocumentRenderingContext(outputDirectory, getOutputName(), reportMojoInfo); + new DocumentRenderingContext(outputDirectory, getOutputPath(), reportMojoInfo); SiteRendererSink sink = new SiteRendererSink(docRenderingContext);