You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by mi...@apache.org on 2022/09/14 20:24:18 UTC

[maven-shared-io] 03/03: [MSHARED-1143] Remove e.getMessage() duplication when e is passed as object

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

michaelo pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/maven-shared-io.git

commit f8f263321ab70119eebb16b426e3a38833fa0e42
Author: Koziolek <bj...@gmail.com>
AuthorDate: Wed Sep 14 22:05:57 2022 +0200

    [MSHARED-1143] Remove e.getMessage() duplication when e is passed as object
    
    This closes #17
---
 .../maven/shared/io/download/DefaultDownloadManager.java     | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/src/main/java/org/apache/maven/shared/io/download/DefaultDownloadManager.java b/src/main/java/org/apache/maven/shared/io/download/DefaultDownloadManager.java
index a349599..887f204 100644
--- a/src/main/java/org/apache/maven/shared/io/download/DefaultDownloadManager.java
+++ b/src/main/java/org/apache/maven/shared/io/download/DefaultDownloadManager.java
@@ -113,7 +113,7 @@ public class DefaultDownloadManager
         }
         catch ( UnsupportedProtocolException e )
         {
-            throw new DownloadFailedException( url, "Download failed.", e );
+            throw new DownloadFailedException( url, "Download failed", e );
         }
 
         messageHolder.addMessage( "Using wagon: " + wagon + " to download: " + url );
@@ -155,11 +155,11 @@ public class DefaultDownloadManager
         }
         catch ( ConnectionException e )
         {
-            throw new DownloadFailedException( url, "Download failed.", e );
+            throw new DownloadFailedException( url, "Download failed", e );
         }
         catch ( AuthenticationException e )
         {
-            throw new DownloadFailedException( url, "Download failed.", e );
+            throw new DownloadFailedException( url, "Download failed", e );
         }
 
         messageHolder.addMessage( "Getting: " + remotePath );
@@ -175,15 +175,15 @@ public class DefaultDownloadManager
         }
         catch ( TransferFailedException e )
         {
-            throw new DownloadFailedException( url, "Download failed.", e );
+            throw new DownloadFailedException( url, "Download failed", e );
         }
         catch ( ResourceDoesNotExistException e )
         {
-            throw new DownloadFailedException( url, "Download failed.", e );
+            throw new DownloadFailedException( url, "Download failed", e );
         }
         catch ( AuthorizationException e )
         {
-            throw new DownloadFailedException( url, "Download failed.", e );
+            throw new DownloadFailedException( url, "Download failed", e );
         }
         finally
         {