Sha256: 824c9dafdaa84ad877b6a97f19b980494034f7cf02659b9e181edd8a59e1be07
Contents?: true
Size: 750 Bytes
Versions: 4
Compression:
Stored size: 750 Bytes
Contents
class SlackSmartBot # helpadmin: ---------------------------------------------- # helpadmin: `start bot` # helpadmin: `start this bot` # helpadmin: the bot will start to listen # helpadmin: You can use this command only if you are an admin user # helpadmin: def start_bot(dest, from) if config.admins.include?(from) #admin user respond "This bot is running and listening from now on. You can pause again: pause this bot", dest @status = :on @bots_created[@channel_id][:status] = :on unless config.on_master_bot send_msg_channel config.master_channel, "Changed status on #{config.channel} to :on" end else respond "Only admin users can change my status", dest end end end
Version data entries
4 entries across 4 versions & 1 rubygems