new GuildStorageRegistry()
Stores all guild-specific storages as <
string
, GuildStorage
> pairs,
where string
is the guild's ID string
Extends
Methods
.findAll(key: string, value: *) → Collection<string, GuildStorage>
Return a
Collection
of GuildStorage items that
have the provided key and value
Parameters:
Name | Type | Description |
---|---|---|
key |
|
Setting key to match |
value |
|
Value to match |
.findAllBySetting(key: string, value: *) → Collection<string, GuildStorage>
Return a
Collection
of GuildStorage items that
have the provided setting key and value
Parameters:
Name | Type | Description |
---|---|---|
key |
|
Setting key to match |
value |
|
Value to match |
.get(guild: Guild) → GuildStorage
Get the GuildStorage by
Guild
or guild id string
Parameters:
Name | Type | Description |
---|---|---|
guild |
|
Guild object or guild id string |
.resetAllGuildSettings(defaults: DefaultGuildSettings)
Reset all guild settings to default, deleting any extra settings that are
not part of the
DefaultGuildSettings
Parameters:
Name | Type | Description |
---|---|---|
defaults |
|
Should always use DefaultGuildSettings |