Exemplo n.º 1
0
        public async Task PairChannelsAsync(ulong guildId, ulong textChannelId, ulong voiceChannelId)
        {
            TextChannelSetting textChannel = await this.AddOrGetTextChannelAsync(guildId, textChannelId);

            textChannel.VoiceChannelId = voiceChannelId;
            await this.Context.SaveChangesAsync();
        }
Exemplo n.º 2
0
        public async Task <ulong?> GetPairedVoiceChannelIdOrNullAsync(ulong textChannelId)
        {
            TextChannelSetting textChannel = await this.Context.FindAsync <TextChannelSetting>(textChannelId);

            return(textChannel?.VoiceChannelId);
        }