internal new static RpcVoiceChannel Create(DiscordRpcClient discord, Model model) { var entity = new RpcVoiceChannel(discord, model.Id, model.GuildId.Value); entity.Update(model); return(entity); }
internal new static RpcGuildChannel Create(DiscordRpcClient discord, Model model) { switch (model.Type) { case ChannelType.Text: return(RpcTextChannel.Create(discord, model)); case ChannelType.Voice: return(RpcVoiceChannel.Create(discord, model)); default: throw new InvalidOperationException("Unknown guild channel type"); } }