You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by rf...@apache.org on 2018/12/24 08:12:14 UTC

[maven-javadoc-plugin] 01/01: Don't fail if module source path already exists. Improved error message if IOException is thrown (added chained exception).

This is an automated email from the ASF dual-hosted git repository.

rfscholte pushed a commit to branch MJAVADOC-554
in repository https://gitbox.apache.org/repos/asf/maven-javadoc-plugin.git

commit 5ed9837ffd65610eea32a44d43a27a15d086557d
Author: Gili Tzabari <a-...@expedia.com>
AuthorDate: Sun Dec 23 21:50:40 2018 -0500

    Don't fail if module source path already exists. Improved error message if IOException is thrown (added chained exception).
---
 .../java/org/apache/maven/plugins/javadoc/AbstractJavadocMojo.java    | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/main/java/org/apache/maven/plugins/javadoc/AbstractJavadocMojo.java b/src/main/java/org/apache/maven/plugins/javadoc/AbstractJavadocMojo.java
index 523014e..d1560cf 100644
--- a/src/main/java/org/apache/maven/plugins/javadoc/AbstractJavadocMojo.java
+++ b/src/main/java/org/apache/maven/plugins/javadoc/AbstractJavadocMojo.java
@@ -4754,11 +4754,11 @@ public abstract class AbstractJavadocMojo
                             addArgIfNotEmpty( arguments, "--patch-module", moduleName + '='
                                 + JavadocUtil.quotedPathArgument( getSourcePath( projectSourcepaths.getValue() ) ) );
                             
-                            Files.createDirectory( moduleSourceDir.resolve( moduleName ) );
+                            Files.createDirectories( moduleSourceDir.resolve( moduleName ) );
                         }
                         catch ( IOException e )
                         {
-                            throw new MavenReportException( e.getMessage() );
+                            throw new MavenReportException( e.getMessage(), e );
                         }
                     }
                     else