summaryrefslogtreecommitdiffstats
path: root/sonar-batch
diff options
context:
space:
mode:
authorsimonbrandhof <simon.brandhof@gmail.com>2011-01-13 00:55:13 +0100
committersimonbrandhof <simon.brandhof@gmail.com>2011-01-13 00:55:13 +0100
commit01dd87a3ee2cd4d8fcdbcd398e3c78f1334e64a7 (patch)
tree7a219437b3e97cf2f8df869bba724b2b8df09190 /sonar-batch
parent5a8ac313e2317c13b0da23ec76b10b40d479b46c (diff)
downloadsonarqube-01dd87a3ee2cd4d8fcdbcd398e3c78f1334e64a7.tar.gz
sonarqube-01dd87a3ee2cd4d8fcdbcd398e3c78f1334e64a7.zip
fix tracking of violations when message starts or ends with whitespaces
Diffstat (limited to 'sonar-batch')
-rw-r--r--sonar-batch/src/main/java/org/sonar/batch/index/ViolationPersister.java1
1 files changed, 1 insertions, 0 deletions
diff --git a/sonar-batch/src/main/java/org/sonar/batch/index/ViolationPersister.java b/sonar-batch/src/main/java/org/sonar/batch/index/ViolationPersister.java
index 48c410cc4a6..13fa2554aeb 100644
--- a/sonar-batch/src/main/java/org/sonar/batch/index/ViolationPersister.java
+++ b/sonar-batch/src/main/java/org/sonar/batch/index/ViolationPersister.java
@@ -57,6 +57,7 @@ public final class ViolationPersister {
model.setSnapshotId(snapshot.getId());
model.setChecksum(checksum);
session.save(model);
+ violation.setMessage(model.getMessage());// the message can be changed in the class RuleFailure (truncate + trim)
violation.setCreatedAt(model.getCreatedAt());
}