private void SendSlackMessage(SlackMessage slackMessage) { // returns void if message is empty if (string.IsNullOrWhiteSpace(slackMessage.Text)) { return; } MessageService = new MessageService(slackMessage.Text, BotUser.Id); // Bot only works in groups if (!slackMessage.IsDirectMessage()) { // returns void if there are only mention if (!MessageService.HasAnyCommand()) { return; } RunsActionMethod(slackMessage); } }