Skip to content
This repository was archived by the owner on Sep 2, 2025. It is now read-only.

Commit b7e31a3

Browse files
committed
TelegramTypes: added deprecated but still used Message::$new_chat_participant and Message::$left_chat_participant
1 parent e93fd5e commit b7e31a3

File tree

1 file changed

+19
-1
lines changed

1 file changed

+19
-1
lines changed

src/Telegram/Types/Message.php

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -258,17 +258,33 @@ class Message extends TelegramTypes
258258
/**
259259
* Optional. A new member was added to the group, information about them (this member may be the bot itself)
260260
*
261-
* @deprecated
261+
* @deprecated Backward compatibility, use $new_chat_members array instead
262262
* @var User
263263
*/
264264
public $new_chat_member;
265265

266+
/**
267+
* Optional. A new member was added to the group, information about them (this member may be the bot itself)
268+
*
269+
* @deprecated Backward compatibility, use $new_chat_members array instead
270+
* @var User
271+
*/
272+
public $new_chat_participant;
273+
266274
/**
267275
* Optional. A member was removed from the group, information about them (this member may be the bot itself)
268276
* @var User
269277
*/
270278
public $left_chat_member;
271279

280+
/**
281+
* Optional. A member was removed from the group, information about them (this member may be the bot itself)
282+
*
283+
* @deprecated Backward compatibility, use $left_chat_member instead
284+
* @var User
285+
*/
286+
public $left_chat_participant;
287+
272288
/**
273289
* Optional. A chat title was changed to this value
274290
* @var string
@@ -401,7 +417,9 @@ protected function mapSubObjects(string $key, array $data): TelegramTypes
401417
case 'from':
402418
case 'forward_from':
403419
case 'new_chat_member':
420+
case 'new_chat_participant':
404421
case 'left_chat_member':
422+
case 'left_chat_participant':
405423
case 'via_bot':
406424
return new User($data, $this->logger);
407425
case 'new_chat_members':

0 commit comments

Comments
 (0)