From 2af73046fc16c645467ef0c20f26e08b117b24e4 Mon Sep 17 00:00:00 2001 From: RogueException Date: Sun, 25 Oct 2015 05:05:51 -0300 Subject: [PATCH] Fixed GlobalUser.PrivateChannel --- src/Discord.Net/Models/Channel.cs | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/Discord.Net/Models/Channel.cs b/src/Discord.Net/Models/Channel.cs index 61bb240b8..610100431 100644 --- a/src/Discord.Net/Models/Channel.cs +++ b/src/Discord.Net/Models/Channel.cs @@ -83,9 +83,14 @@ namespace Discord x => { Name = "@" + x.Name; - x.GlobalUser.PrivateChannel = this; + if (_server.Id == null) + x.GlobalUser.PrivateChannel = this; }, - x => x.GlobalUser.PrivateChannel = null); + x => + { + if (_server.Id == null) + x.GlobalUser.PrivateChannel = null; + }); _permissionOverwrites = _initialPermissionsOverwrites; _areMembersStale = true;