Browse Source

Exposed User.PrivateChannel

tags/docs-0.9
RogueException 9 years ago
parent
commit
47269aa420
1 changed files with 4 additions and 0 deletions
  1. +4
    -0
      src/Discord.Net/Models/User.cs

+ 4
- 0
src/Discord.Net/Models/User.cs View File

@@ -48,6 +48,10 @@ namespace Discord
public DateTime LastOnlineAt => Status != UserStatus.Offline ? DateTime.UtcNow : _lastOnline;
private DateTime _lastOnline;

/// <summary> Returns the private messaging channel with this user, if one exists. </summary>
[JsonIgnore]
public Channel PrivateChannel => GlobalUser.PrivateChannel;

[JsonIgnore]
internal GlobalUser GlobalUser => _globalUser.Value;
private readonly Reference<GlobalUser> _globalUser;


Loading…
Cancel
Save