]> source.dussan.org Git - sonarqube.git/commitdiff
Fix some other quality flaws
authorSimon Brandhof <simon.brandhof@sonarsource.com>
Thu, 30 Apr 2015 08:27:27 +0000 (10:27 +0200)
committerSimon Brandhof <simon.brandhof@sonarsource.com>
Thu, 30 Apr 2015 08:27:27 +0000 (10:27 +0200)
plugins/sonar-email-notifications-plugin/src/main/java/org/sonar/plugins/emailnotifications/AlertsEmailTemplate.java
server/sonar-server/src/main/java/org/sonar/server/startup/LogServerId.java

index 542d35204f4a6b4d14368a8c1ee15b7c163a1645..a66444ad83845bf50a112b96371d5bd647de8096 100644 (file)
@@ -52,7 +52,7 @@ public class AlertsEmailTemplate extends EmailTemplate {
     String alertName = notification.getFieldValue("alertName");
     String alertText = notification.getFieldValue("alertText");
     String alertLevel = notification.getFieldValue("alertLevel");
-    boolean isNewAlert = Boolean.valueOf(notification.getFieldValue("isNewAlert"));
+    boolean isNewAlert = Boolean.parseBoolean(notification.getFieldValue("isNewAlert"));
 
     // Generate text
     String subject = generateSubject(projectName, alertLevel, isNewAlert);
index cf6ea5dd47dfdc0bdc8eef7363bb79ff31f228cc..5fcbeb02a3ed2ba36f5a7929f410166611f8b961 100644 (file)
@@ -42,7 +42,7 @@ public final class LogServerId {
   }
 
   @VisibleForTesting
-  protected void logServerId(Logger logger) {
+  void logServerId(Logger logger) {
     PropertyDto serverIdProp = propertiesDao.selectGlobalProperty(CoreProperties.PERMANENT_SERVER_ID);
     if (serverIdProp != null) {
       // a server ID has been generated, let's print out the other useful informations that can help debugging license issues