diff --git a/pom.xml b/pom.xml index 2c581e2..f61a649 100644 --- a/pom.xml +++ b/pom.xml @@ -107,13 +107,13 @@ dev.struchkov.haiti haiti-utils - 2.3.4 + 2.5.0 dev.struchkov.haiti haiti-exception - 2.3.4 + 2.5.0 diff --git a/telegram-bot/src/main/java/dev/struchkov/bot/gitlab/telegram/service/StartNotify.java b/telegram-bot/src/main/java/dev/struchkov/bot/gitlab/telegram/service/StartNotify.java index c41b20e..858bd08 100644 --- a/telegram-bot/src/main/java/dev/struchkov/bot/gitlab/telegram/service/StartNotify.java +++ b/telegram-bot/src/main/java/dev/struchkov/bot/gitlab/telegram/service/StartNotify.java @@ -27,11 +27,10 @@ public class StartNotify { final BoxAnswer boxAnswer = BoxAnswer.builder() .recipientPersonId(personProperty.getTelegramId()) .message( - new StringBuilder() - .append("Hello. I wish you a productive day :)") - .append("\n-- -- -- -- --\n") - .append("Version ").append(appProperty.getVersion()).append(" | Developer: [uPagge](https://mark.struchkov.dev)") - .toString() + "Hello. I wish you a productive work day \uD83C\uDF40" + + "\n-- -- -- -- --\n" + + "Version " + appProperty.getVersion() + + "\nDeveloper: [uPagge](https://mark.struchkov.dev)" ).build(); sending.send(boxAnswer); diff --git a/telegram-bot/src/main/java/dev/struchkov/bot/gitlab/telegram/service/notify/NewProjectNotifyGenerator.java b/telegram-bot/src/main/java/dev/struchkov/bot/gitlab/telegram/service/notify/NewProjectNotifyGenerator.java index a20f1b0..7e2ba59 100644 --- a/telegram-bot/src/main/java/dev/struchkov/bot/gitlab/telegram/service/notify/NewProjectNotifyGenerator.java +++ b/telegram-bot/src/main/java/dev/struchkov/bot/gitlab/telegram/service/notify/NewProjectNotifyGenerator.java @@ -4,6 +4,7 @@ import dev.struchkov.bot.gitlab.context.domain.notify.project.NewProjectNotify; import dev.struchkov.bot.gitlab.context.utils.Icons; import dev.struchkov.bot.gitlab.telegram.utils.Const; import dev.struchkov.godfather.main.domain.BoxAnswer; +import dev.struchkov.haiti.utils.Checker; import dev.struchkov.haiti.utils.Strings; import org.springframework.stereotype.Component; @@ -23,7 +24,7 @@ public class NewProjectNotifyGenerator implements NotifyBoxAnswerGenerator optDescription = Optional.ofNullable(notify.getProjectDescription()) - .filter(Strings.EMPTY::equals) + .filter(Checker::checkNotBlank) .map(Strings::escapeMarkdown); final StringBuilder builder = new StringBuilder(Icons.FUN).append("* New project*")