Skip to content

Commit aac4831

Browse files
author
Valentin Gerbey
committed
Added custom_emoji message entity type
1 parent 1970f9a commit aac4831

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/Api/Type/Message/MessageEntityType.php

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,8 @@ final class MessageEntityType implements Enum
4545

4646
private const MENTION = 'mention';
4747

48+
private const CUSTOM_EMOJI = 'custom_emoji';
49+
4850
private const LIST = [
4951
self::HASH_TAG,
5052
self::CASH_TAG,
@@ -59,6 +61,7 @@ final class MessageEntityType implements Enum
5961
self::TEXT_LINK,
6062
self::TEXT_MENTION,
6163
self::MENTION,
64+
self::CUSTOM_EMOJI,
6265
];
6366

6467
/**
@@ -141,6 +144,11 @@ public static function mention(): self
141144
return new self(self::MENTION);
142145
}
143146

147+
public static function customEmoji(): self
148+
{
149+
return new self(self::CUSTOM_EMOJI);
150+
}
151+
144152
public function equals(MessageEntityType $type): bool
145153
{
146154
return $this->value === $type->value;

0 commit comments

Comments
 (0)