lib/smart_todo/dispatchers/slack.rb
def slack_user_or_channel(assignee)
        if assignee.include?("@")
          client.lookup_user_by_email(assignee)
        else
          { "user" => { "id" => assignee } }
        end
      end
# Returns a formatted hash containing either the user id of a slack user or
# the channel the message should be sent to.
#
# @return [Hash] a suited hash containing the user ID for a given individual or a slack channel
Returns a formatted hash containing either the user id of a slack user or
the channel the message should be sent to.
Returns a formatted hash containing either the user id of a slack user or the channel the message should be sent to .
def slack_user_or_channel(assignee)
        if assignee.include?("@")
          client.lookup_user_by_email(assignee)
        else
          { "user" => { "id" => assignee } }
        end
      end
def slack_user_or_channel ( assignee ) if assignee . include? ( "@" ) client . lookup_user_by_email ( assignee ) else { "user" => { "id" => assignee } } end end
Returns a formatted hash containing either the user id of a slack user or
the channel the message should be sent to.
Returns a formatted hash containing either the user id of a slack user or the channel the message should be sent to .
a suited hash containing the user ID for a given individual or a slack channel
a suited hash containing the user ID for a given individual or a slack channel
Hash
assignee