Skip to content

Commit

Permalink
Merge pull request #95 from IanLeeClaxton/feature/fix_missing_user_icons
Browse files Browse the repository at this point in the history
Missing bot user image in Slack
  • Loading branch information
alexkvak authored Mar 21, 2020
2 parents f8c9abe + 78abf3a commit ea1075e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,12 @@ class SlackGateway(val configManager: ConfigManager, logger: Logger) {
}

private def channelChatConfiguration =
SlackChatConfiguration.getConfiguration.withName(configManager.senderName.getOrElse(Strings.channelMessageOwner))
configManager.senderName match {
case Some(senderName)
SlackChatConfiguration.getConfiguration.withName(senderName)
case _
SlackChatConfiguration.getConfiguration.asUser()
}

private def sendMessageInternal(destination: Destination, message: SlackMessage): MessageSent = session match {
case Some(x)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ object Strings {
lazy val logCategory = "Slack Integration"
def label: String = "Slack"
def tabId: String = "Slack"
lazy val channelMessageOwner = "TeamCity"

private def unableToCreateSessionByConfig(reason: String): String = s"Unable to create session by config: $reason"

Expand Down

0 comments on commit ea1075e

Please sign in to comment.