Skip to content

Commit

Permalink
Fix name of integration
Browse files Browse the repository at this point in the history
(cherry picked from commit 8968888)
  • Loading branch information
APiankouski committed Sep 16, 2024
1 parent 04ce996 commit 06f25e7
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@
import java.util.stream.Collectors;
import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.lang3.BooleanUtils;
import org.apache.commons.lang3.StringUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
Expand All @@ -68,7 +69,7 @@ public class LaunchNotificationRunner

private static final Logger LOGGER = LoggerFactory.getLogger(LaunchNotificationRunner.class);

private static final String EMAIL_INTEGRATION_NAME = "email server";
private static final String EMAIL_INTEGRATION_NAME = "Email Server";

private final static String NOTIFICATION_TYPE = "email";

Expand Down Expand Up @@ -101,7 +102,7 @@ public void handle(LaunchFinishedEvent launchFinishedEvent, Map<String, String>
if (isNotificationsEnabled) {
getIntegrationHandler.getEnabledByProjectIdOrGlobalAndIntegrationGroup(
launchFinishedEvent.getProjectId(), IntegrationGroupEnum.NOTIFICATION)
.filter(integration -> EMAIL_INTEGRATION_NAME.equals(integration.getName()))
.filter(integration -> EMAIL_INTEGRATION_NAME.equalsIgnoreCase(integration.getName()))
.flatMap(mailServiceFactory::getDefaultEmailService)
.ifPresentOrElse(emailService -> sendEmail(launchFinishedEvent, emailService),
() -> LOGGER.warn("Unable to find {} integration for project {}",
Expand Down

0 comments on commit 06f25e7

Please sign in to comment.