Sha256: b568a7b6aec43530c0eeacf5a0abdf01f5a6a99cc77d89b39020ed819c01d853
Contents?: true
Size: 663 Bytes
Versions: 3
Compression:
Stored size: 663 Bytes
Contents
# frozen_string_literal: true require_relative 'ids.id' module Slack module Web module Api module Mixins module Channels include Ids # # This method returns a channel ID given a channel name. # # @option options [channel] :channel # Channel to get ID for, prefixed with #. def channels_id(options = {}) name = options[:channel] throw ArgumentError.new('Required arguments :channel missing') if name.nil? id_for :channel, name, '#', :channels_list, :channels, 'channel_not_found' end end end end end end
Version data entries
3 entries across 3 versions & 1 rubygems