Sha256: ff0590b9757b9be0e032c505f79ef9de9b8785c943e5d594a306208b33ae3f90

Contents?: true

Size: 840 Bytes

Versions: 17

Compression:

Stored size: 840 Bytes

Contents

class SlackSmartBot

    # helpadmin: ----------------------------------------------
    # helpadmin: `get bot logs`
    # helpadmin:    To see the bot logs
    # helpadmin:    You can use this command only if you are a Master admin user and if you are in a private conversation with the bot
    # helpadmin: command_id: :get_bot_logs
    # helpadmin:
    def get_bot_logs(dest, from, typem)
      save_stats(__method__)
      if config.masters.include?(from) and typem==:on_dm #master admin user
        respond 'Remember this data is private'
        send_file(dest, "Logs for #{config.channel}", "#{config.path}/logs/#{config.log_file}", 'Remember this data is private', 'text/plain', "text")
      else
        respond "Only master admin users on a private conversation with the bot can get the bot logs.", dest
      end
    end
end
  

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
slack-smart-bot-1.14.2 lib/slack/smart-bot/commands/on_bot/admin_master/get_bot_logs.rb
slack-smart-bot-1.14.1 lib/slack/smart-bot/commands/on_bot/admin_master/get_bot_logs.rb
slack-smart-bot-1.14.0 lib/slack/smart-bot/commands/on_bot/admin_master/get_bot_logs.rb
slack-smart-bot-1.13.2 lib/slack/smart-bot/commands/on_bot/admin_master/get_bot_logs.rb
slack-smart-bot-1.13.1 lib/slack/smart-bot/commands/on_bot/admin_master/get_bot_logs.rb
slack-smart-bot-1.13.0 lib/slack/smart-bot/commands/on_bot/admin_master/get_bot_logs.rb
slack-smart-bot-1.12.9 lib/slack/smart-bot/commands/on_bot/admin_master/get_bot_logs.rb
slack-smart-bot-1.12.8 lib/slack/smart-bot/commands/on_bot/admin_master/get_bot_logs.rb
slack-smart-bot-1.12.7 lib/slack/smart-bot/commands/on_bot/admin_master/get_bot_logs.rb
slack-smart-bot-1.12.6 lib/slack/smart-bot/commands/on_bot/admin_master/get_bot_logs.rb
slack-smart-bot-1.12.5 lib/slack/smart-bot/commands/on_bot/admin_master/get_bot_logs.rb
slack-smart-bot-1.12.4 lib/slack/smart-bot/commands/on_bot/admin_master/get_bot_logs.rb
slack-smart-bot-1.12.3 lib/slack/smart-bot/commands/on_bot/admin_master/get_bot_logs.rb
slack-smart-bot-1.12.2 lib/slack/smart-bot/commands/on_bot/admin_master/get_bot_logs.rb
slack-smart-bot-1.12.1 lib/slack/smart-bot/commands/on_bot/admin_master/get_bot_logs.rb
slack-smart-bot-1.12.0 lib/slack/smart-bot/commands/on_bot/admin_master/get_bot_logs.rb
slack-smart-bot-1.11.0 lib/slack/smart-bot/commands/on_bot/admin_master/get_bot_logs.rb