Module: Discordrb
- Defined in:
- lib/discordrb.rb,
lib/discordrb/bot.rb,
lib/discordrb/data.rb,
lib/discordrb/await.rb,
lib/discordrb/logger.rb,
lib/discordrb/version.rb,
lib/discordrb/exceptions.rb,
lib/discordrb/permissions.rb,
lib/discordrb/token_cache.rb
Overview
Discordrb
Defined Under Namespace
Modules: API, Commands, Events, Voice Classes: Await, Bot, CachedToken, Channel, ColourRGB, HTTPStatusException, InvalidAuthenticationException, Invite, Logger, Message, Permissions, Profile, Role, Server, TokenCache, User
Constant Summary collapse
- LOGGER =
Logger.new
- ColorRGB =
ColourRGB- VERSION =
'1.5.1'- KEYLEN =
Amount of bytes the key should be long (32 bytes = 256 bits -> AES256)
32- CACHE_PATH =
Path where the cache file will be stored
Dir.home + '/.discordrb_token_cache.json'
Class Method Summary collapse
-
.id_compare(one_id, other) ⇒ Object
Compares two objects based on IDs - either the objects' IDs are equal, or one object is equal to the other's ID.
Class Method Details
.id_compare(one_id, other) ⇒ Object
Compares two objects based on IDs - either the objects' IDs are equal, or one object is equal to the other's ID.
13 14 15 |
# File 'lib/discordrb/data.rb', line 13 def self.id_compare(one_id, other) other.respond_to?(:id) ? (one_id == other.id) : (one_id == other) end |