From 81b76d8b6cbc8cc685c57e42d7a9c5a8dfac2ab6 Mon Sep 17 00:00:00 2001 From: David Gageot Date: Mon, 5 Nov 2012 10:01:22 +0100 Subject: [PATCH] SONAR-3895 Fix violations --- .../src/main/java/org/sonar/batch/local/DryRunDatabase.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sonar-batch/src/main/java/org/sonar/batch/local/DryRunDatabase.java b/sonar-batch/src/main/java/org/sonar/batch/local/DryRunDatabase.java index 8a5bf928576..c2f69706d58 100644 --- a/sonar-batch/src/main/java/org/sonar/batch/local/DryRunDatabase.java +++ b/sonar-batch/src/main/java/org/sonar/batch/local/DryRunDatabase.java @@ -86,9 +86,9 @@ public class DryRunDatabase implements BatchComponent { } catch (SonarException e) { Throwable rootCause = Throwables.getRootCause(e); if (rootCause instanceof FileNotFoundException) { - throw new SonarException(String.format("Project [%s] doesn't exist on server", projectKey)); + throw new SonarException(String.format("Project [%s] doesn't exist on server", projectKey), e); } else if ((rootCause instanceof IOException) && (StringUtils.contains(rootCause.getMessage(), "401"))) { - throw new SonarException(String.format("You don't have access rights to project [%s]", projectKey)); + throw new SonarException(String.format("You don't have access rights to project [%s]", projectKey), e); } throw e; } -- 2.39.5