[Feature] Public constructor for Emote (#2936)
This commit is contained in:
@@ -31,8 +31,13 @@ namespace Discord
|
|||||||
/// </returns>
|
/// </returns>
|
||||||
public string Url => CDN.GetEmojiUrl(Id, Animated);
|
public string Url => CDN.GetEmojiUrl(Id, Animated);
|
||||||
|
|
||||||
internal Emote(ulong id, string name, bool animated)
|
/// <summary>
|
||||||
|
/// Creates a new instance of <see cref="Emote" />.
|
||||||
|
/// </summary>
|
||||||
|
public Emote(ulong id, string name, bool animated = false)
|
||||||
{
|
{
|
||||||
|
if (string.IsNullOrWhiteSpace(name))
|
||||||
|
throw new ArgumentException("A custom emote must have a name", nameof(name));
|
||||||
Id = id;
|
Id = id;
|
||||||
Name = name;
|
Name = name;
|
||||||
Animated = animated;
|
Animated = animated;
|
||||||
|
|||||||
Reference in New Issue
Block a user