diff --git a/src/main/java/jenkins/plugins/slack/ActiveNotifier.java b/src/main/java/jenkins/plugins/slack/ActiveNotifier.java index 03ab2ecd..2440ad7c 100755 --- a/src/main/java/jenkins/plugins/slack/ActiveNotifier.java +++ b/src/main/java/jenkins/plugins/slack/ActiveNotifier.java @@ -242,7 +242,7 @@ public MessageBuilder appendStatusMessage() { return this; } - static String getStatusMessage(AbstractBuild r) { + private String getStatusMessage(AbstractBuild r) { if (r.isBuilding()) { return STARTING_STATUS_MESSAGE; } @@ -279,7 +279,7 @@ static String getStatusMessage(AbstractBuild r) { */ if (result == Result.SUCCESS && (previousResult == Result.FAILURE || previousResult == Result.UNSTABLE) - && buildHasSucceededBefore) { + && buildHasSucceededBefore && notifier.getNotifyBackToNormal()) { return BACK_TO_NORMAL_STATUS_MESSAGE; } if (result == Result.FAILURE && previousResult == Result.FAILURE) {