forked from TeamInklings/Octobot
Unload guild datas when they become unavailable (#146)
Closes #120 --------- Signed-off-by: Macintosh II <mctaylxrs@outlook.com> Signed-off-by: Macintosh II <95250141+mctaylors@users.noreply.github.com>
This commit is contained in:
parent
777dbc6eec
commit
68d1534b26
2 changed files with 43 additions and 0 deletions
|
@ -142,4 +142,9 @@ public sealed class GuildDataService : IHostedService
|
|||
{
|
||||
return _datas.Keys;
|
||||
}
|
||||
|
||||
public bool UnloadGuildData(Snowflake id)
|
||||
{
|
||||
return _datas.TryRemove(id, out _);
|
||||
}
|
||||
}
|
||||
|
|
Reference in a new issue