Constructor
new BotConfig()
Properties:
Name | Type | Description |
---|---|---|
storage |
Object | The current storage object. |
defaults |
Object | The default configuration set before starting the bot located in ../config.json |
configExists |
boolean | Indicator whether default configuration exists |
- Version:
-
- 1.0
- Source:
Methods
(static) getInstance() → {Object}
Singleton method. Create a single instance of this object.
- Source:
loadGuildChannels(guildId) → {Object}
Load the channel configuration for a specific guild.
Parameters:
Name | Type | Description |
---|---|---|
guildId |
* | Unique identifier of the guild |
- Source:
setGuildChannels(guildId, channelConfig)
Updates the channel configuration for a specific guild.
Parameters:
Name | Type | Description |
---|---|---|
guildId |
* | Unique identifier of the guild |
channelConfig |
Object | The new channel configuration |
- Source:
loadGuildQueue(guildId) → {Object}
Loads the current configurration for the guild queue.
Parameters:
Name | Type | Description |
---|---|---|
guildId |
* | The unique identifer of the guild. |
- Source:
setGuildQueue(guildId)
Set the current configuration for the guild queue.
Parameters:
Name | Type | Description |
---|---|---|
guildId |
* | The unique identifer of the guild |
- Source:
getDefaultConfig() → {Object}
Return the default configuration that was loaded into the bot configuration instance.
- Source:
getGuildConfig(guildId) → {Object}
Get guild specific configuration.
Parameters:
Name | Type | Description |
---|---|---|
guildId |
* | The id of the guild. |
- Source:
setGuildConfig(guildId, config)
Set guild specific configuration.
Parameters:
Name | Type | Description |
---|---|---|
guildId |
* | The id of the guild |
config |
* | The new guild configuration |
- Source:
exists() → {boolean}
Returns whether a bot configuration file exists and is loaded or not.
- Source: