@@ -23,23 +23,23 @@ discard block |
||
23 | 23 | public string $file_unique_id; |
24 | 24 | |
25 | 25 | /** Optional. Document thumbnail as defined by sender */ |
26 | - public null|photoSize $thumbnail = null; |
|
26 | + public null | photoSize $thumbnail = null; |
|
27 | 27 | |
28 | 28 | /** Optional. Original filename as defined by sender */ |
29 | - public null|string $file_name = null; |
|
29 | + public null | string $file_name = null; |
|
30 | 30 | |
31 | 31 | /** Optional. MIME type of the file as defined by sender */ |
32 | - public null|string $mime_type = null; |
|
32 | + public null | string $mime_type = null; |
|
33 | 33 | |
34 | 34 | /** |
35 | 35 | * Optional. File size in bytes. It can be bigger than 2^31 and some programming languages may have |
36 | 36 | * difficulty/silent defects in interpreting it. But it has at most 52 significant bits, so a signed 64-bit |
37 | 37 | * integer or double-precision float type are safe for storing this value. |
38 | 38 | */ |
39 | - public null|int $file_size = null; |
|
39 | + public null | int $file_size = null; |
|
40 | 40 | |
41 | 41 | |
42 | - public function __construct(stdClass|null $object = null) { |
|
42 | + public function __construct(stdClass | null $object = null) { |
|
43 | 43 | if ($object != null) { |
44 | 44 | parent::__construct($object, self::subs); |
45 | 45 | } |
@@ -60,8 +60,8 @@ discard block |
||
60 | 60 | * |
61 | 61 | * @return bool|string string will be returned when destination doesn't set |
62 | 62 | */ |
63 | - public function download(string|null $destination = null): bool|string { |
|
64 | - return telegram::downloadFile($destination ?? $this->file_name ?? 'unknown.txt',$this->file_id); |
|
63 | + public function download(string | null $destination = null): bool | string { |
|
64 | + return telegram::downloadFile($destination ?? $this->file_name ?? 'unknown.txt', $this->file_id); |
|
65 | 65 | } |
66 | 66 | |
67 | 67 | /** |
@@ -75,7 +75,7 @@ discard block |
||
75 | 75 | return telegram::fileLink($this->file_id); |
76 | 76 | } |
77 | 77 | |
78 | - public function typedSize (int $precision = 2, bool $space_between = true): string { |
|
78 | + public function typedSize(int $precision = 2, bool $space_between = true): string { |
|
79 | 79 | return tools::byteFormat($this->file_id, $precision, $space_between); |
80 | 80 | } |
81 | 81 | } |
@@ -14,7 +14,7 @@ |
||
14 | 14 | /** Number of boosts added by the user */ |
15 | 15 | public int $boost_count; |
16 | 16 | |
17 | - public function __construct(stdClass|null $object = null) { |
|
17 | + public function __construct(stdClass | null $object = null) { |
|
18 | 18 | if ($object != null) { |
19 | 19 | parent::__construct($object, self::subs); |
20 | 20 | } |
@@ -12,31 +12,31 @@ |
||
12 | 12 | private const subs = []; |
13 | 13 | |
14 | 14 | /** Optional. True, if the link preview is disabled */ |
15 | - public null|bool $is_disabled = null; |
|
15 | + public null | bool $is_disabled = null; |
|
16 | 16 | |
17 | 17 | /** Optional. URL to use for the link preview. If empty, then the first URL found in the message text will be used */ |
18 | - public null|string $url = null; |
|
18 | + public null | string $url = null; |
|
19 | 19 | |
20 | 20 | /** |
21 | 21 | * Optional. True, if the media in the link preview is supposed to be shrunk; ignored if the URL isn't explicitly |
22 | 22 | * specified or media size change isn't supported for the preview |
23 | 23 | */ |
24 | - public null|bool $prefer_small_media = null; |
|
24 | + public null | bool $prefer_small_media = null; |
|
25 | 25 | |
26 | 26 | /** |
27 | 27 | * Optional. True, if the media in the link preview is supposed to be enlarged; ignored if the URL isn't |
28 | 28 | * explicitly specified or media size change isn't supported for the preview |
29 | 29 | */ |
30 | - public null|bool $prefer_large_media = null; |
|
30 | + public null | bool $prefer_large_media = null; |
|
31 | 31 | |
32 | 32 | /** |
33 | 33 | * Optional. True, if the link preview must be shown above the message text; otherwise, the link preview will be |
34 | 34 | * shown below the message text |
35 | 35 | */ |
36 | - public null|bool $show_above_text = null; |
|
36 | + public null | bool $show_above_text = null; |
|
37 | 37 | |
38 | 38 | |
39 | - public function __construct(stdClass|null $object = null) { |
|
39 | + public function __construct(stdClass | null $object = null) { |
|
40 | 40 | if ($object != null) { |
41 | 41 | parent::__construct($object, self::subs); |
42 | 42 | } |
@@ -15,21 +15,21 @@ discard block |
||
15 | 15 | * Identifier of the message that will be replied to in the current chat, or in the chat chat_id if it is |
16 | 16 | * specified |
17 | 17 | */ |
18 | - public null|int $message_id; |
|
18 | + public null | int $message_id; |
|
19 | 19 | |
20 | 20 | /** |
21 | 21 | * Optional. If the message to be replied to is from a different chat, unique identifier for the chat or username |
22 | 22 | * of the channel (in the format channelusername). Not supported for messages sent on behalf of a business |
23 | 23 | * account. |
24 | 24 | */ |
25 | - public null|int $chat_id = null; |
|
25 | + public null | int $chat_id = null; |
|
26 | 26 | |
27 | 27 | /** |
28 | 28 | * Optional. Pass True if the message should be sent even if the specified message to be replied to is not found. |
29 | 29 | * Always False for replies in another chat or forum topic. Always True for messages sent on behalf of a business |
30 | 30 | * account. |
31 | 31 | */ |
32 | - public null|bool $allow_sending_without_reply = null; |
|
32 | + public null | bool $allow_sending_without_reply = null; |
|
33 | 33 | |
34 | 34 | /** |
35 | 35 | * Optional. Quoted part of the message to be replied to; 0-1024 characters after entities parsing. The quote |
@@ -37,23 +37,23 @@ discard block |
||
37 | 37 | * spoiler, and custom_emoji entities. The message will fail to send if the quote isn't found in the original |
38 | 38 | * message. |
39 | 39 | */ |
40 | - public null|string $quote = null; |
|
40 | + public null | string $quote = null; |
|
41 | 41 | |
42 | 42 | /** Optional. Mode for parsing entities in the quote. See formatting options for more details. */ |
43 | - public null|string $quote_parse_mode = null; |
|
43 | + public null | string $quote_parse_mode = null; |
|
44 | 44 | |
45 | 45 | /** |
46 | 46 | * Optional. A JSON-serialized list of special entities that appear in the quote. It can be specified instead of |
47 | 47 | * quote_parse_mode. |
48 | 48 | * @var messageEntity[] |
49 | 49 | */ |
50 | - public null|array $quote_entities = null; |
|
50 | + public null | array $quote_entities = null; |
|
51 | 51 | |
52 | 52 | /** Optional. Position of the quote in the original message in UTF-16 code units */ |
53 | - public null|int $quote_position = null; |
|
53 | + public null | int $quote_position = null; |
|
54 | 54 | |
55 | 55 | |
56 | - public function __construct(stdClass|null $object = null) { |
|
56 | + public function __construct(stdClass | null $object = null) { |
|
57 | 57 | if ($object != null) { |
58 | 58 | parent::__construct($object, self::subs); |
59 | 59 | } |
@@ -17,7 +17,7 @@ |
||
17 | 17 | /** Unique identifier for the story in the chat */ |
18 | 18 | public int $id; |
19 | 19 | |
20 | - public function __construct(stdClass|null $object = null) { |
|
20 | + public function __construct(stdClass | null $object = null) { |
|
21 | 21 | if ($object != null) { |
22 | 22 | parent::__construct($object, self::subs); |
23 | 23 | } |
@@ -25,21 +25,21 @@ discard block |
||
25 | 25 | public string $type; |
26 | 26 | |
27 | 27 | /** Optional. Title, for supergroups, channels and group chats */ |
28 | - public null|string $title = null; |
|
28 | + public null | string $title = null; |
|
29 | 29 | |
30 | 30 | /** Optional. Username, for private chats, supergroups and channels if available */ |
31 | - public null|string $username = null; |
|
31 | + public null | string $username = null; |
|
32 | 32 | |
33 | 33 | /** Optional. First name of the other party in a private chat */ |
34 | - public null|string $first_name = null; |
|
34 | + public null | string $first_name = null; |
|
35 | 35 | |
36 | 36 | /** Optional. Last name of the other party in a private chat */ |
37 | - public null|string $last_name = null; |
|
37 | + public null | string $last_name = null; |
|
38 | 38 | |
39 | 39 | /** Optional. True, if the supergroup chat is a forum (has topics enabled) */ |
40 | - public null|bool $is_forum = null; |
|
40 | + public null | bool $is_forum = null; |
|
41 | 41 | |
42 | - public function __construct(stdClass|null $object = null) { |
|
42 | + public function __construct(stdClass | null $object = null) { |
|
43 | 43 | if ($object != null) { |
44 | 44 | parent::__construct($object, self::subs); |
45 | 45 | } |
@@ -50,7 +50,7 @@ discard block |
||
50 | 50 | * |
51 | 51 | * @return bool |
52 | 52 | */ |
53 | - public function isPrivate (): bool { |
|
53 | + public function isPrivate(): bool { |
|
54 | 54 | return $this->type === chatType::PRIVATE; |
55 | 55 | } |
56 | 56 | |
@@ -59,7 +59,7 @@ discard block |
||
59 | 59 | * |
60 | 60 | * @return bool |
61 | 61 | */ |
62 | - public function isGroup (): bool { |
|
62 | + public function isGroup(): bool { |
|
63 | 63 | return $this->type === chatType::GROUP; |
64 | 64 | } |
65 | 65 | |
@@ -68,7 +68,7 @@ discard block |
||
68 | 68 | * |
69 | 69 | * @return bool |
70 | 70 | */ |
71 | - public function isSuperGroup (): bool { |
|
71 | + public function isSuperGroup(): bool { |
|
72 | 72 | return $this->type === chatType::SUPERGROUP; |
73 | 73 | } |
74 | 74 | |
@@ -77,7 +77,7 @@ discard block |
||
77 | 77 | * |
78 | 78 | * @return bool |
79 | 79 | */ |
80 | - public function isChannel (): bool { |
|
80 | + public function isChannel(): bool { |
|
81 | 81 | return $this->type === chatType::CHANNEL; |
82 | 82 | } |
83 | 83 | |
@@ -86,7 +86,7 @@ discard block |
||
86 | 86 | * |
87 | 87 | * @return responseError|bool |
88 | 88 | */ |
89 | - public function leave(): responseError|bool { |
|
89 | + public function leave(): responseError | bool { |
|
90 | 90 | if ($this->isPrivate()) { |
91 | 91 | return false; |
92 | 92 | } |
@@ -101,7 +101,7 @@ discard block |
||
101 | 101 | * |
102 | 102 | * @return responseError|bool |
103 | 103 | */ |
104 | - public function setPhoto(CURLFile|array $photo, bool $answer = null): responseError|bool { |
|
104 | + public function setPhoto(CURLFile | array $photo, bool $answer = null): responseError | bool { |
|
105 | 105 | if ($this->isPrivate()) { |
106 | 106 | return false; |
107 | 107 | } |
@@ -115,7 +115,7 @@ discard block |
||
115 | 115 | * |
116 | 116 | * @return responseError|bool |
117 | 117 | */ |
118 | - public function delPhoto(bool $answer = null): responseError|bool { |
|
118 | + public function delPhoto(bool $answer = null): responseError | bool { |
|
119 | 119 | if ($this->isPrivate()) { |
120 | 120 | return false; |
121 | 121 | } |
@@ -130,7 +130,7 @@ discard block |
||
130 | 130 | * |
131 | 131 | * @return responseError|bool |
132 | 132 | */ |
133 | - public function setTitle(string|array $title, bool $answer = null): responseError|bool { |
|
133 | + public function setTitle(string | array $title, bool $answer = null): responseError | bool { |
|
134 | 134 | if ($this->isPrivate()) { |
135 | 135 | return false; |
136 | 136 | } |
@@ -145,7 +145,7 @@ discard block |
||
145 | 145 | * |
146 | 146 | * @return responseError|bool |
147 | 147 | */ |
148 | - public function setDescription(string|null $description = null, bool $answer = null): responseError|bool { |
|
148 | + public function setDescription(string | null $description = null, bool $answer = null): responseError | bool { |
|
149 | 149 | if ($this->isPrivate()) { |
150 | 150 | return false; |
151 | 151 | } |
@@ -159,7 +159,7 @@ discard block |
||
159 | 159 | * |
160 | 160 | * @return bool|responseError|array |
161 | 161 | */ |
162 | - public function getAdmins(bool $answer = null): bool|responseError|array { |
|
162 | + public function getAdmins(bool $answer = null): bool | responseError | array { |
|
163 | 163 | if ($this->isPrivate()) { |
164 | 164 | return false; |
165 | 165 | } |
@@ -173,7 +173,7 @@ discard block |
||
173 | 173 | * |
174 | 174 | * @return bool|responseError|int |
175 | 175 | */ |
176 | - public function getMembersCount(bool $answer = null): bool|responseError|int { |
|
176 | + public function getMembersCount(bool $answer = null): bool | responseError | int { |
|
177 | 177 | if ($this->isPrivate()) { |
178 | 178 | return false; |
179 | 179 | } |
@@ -188,7 +188,7 @@ discard block |
||
188 | 188 | * |
189 | 189 | * @return chatMember|bool|responseError |
190 | 190 | */ |
191 | - public function getMember(int|null $user_id = null, bool $answer = null): chatMember|bool|responseError { |
|
191 | + public function getMember(int | null $user_id = null, bool $answer = null): chatMember | bool | responseError { |
|
192 | 192 | if ($this->isPrivate()) { |
193 | 193 | return false; |
194 | 194 | } |
@@ -55,28 +55,28 @@ |
||
55 | 55 | * Optional. 0-based identifier of the correct answer option. Available only for polls in the quiz mode, which |
56 | 56 | * are closed, or was sent (not forwarded) by the bot or to the private chat with the bot. |
57 | 57 | */ |
58 | - public null|int $correct_option_id = null; |
|
58 | + public null | int $correct_option_id = null; |
|
59 | 59 | |
60 | 60 | /** |
61 | 61 | * Optional. Text that is shown when a user chooses an incorrect answer or taps on the lamp icon in a quiz-style |
62 | 62 | * poll, 0-200 characters |
63 | 63 | */ |
64 | - public null|string $explanation = null; |
|
64 | + public null | string $explanation = null; |
|
65 | 65 | |
66 | 66 | /** |
67 | 67 | * Optional. Special entities like usernames, URLs, bot commands, etc. that appear in the explanation |
68 | 68 | * @var messageEntity[] |
69 | 69 | */ |
70 | - public null|array $explanation_entities = null; |
|
70 | + public null | array $explanation_entities = null; |
|
71 | 71 | |
72 | 72 | /** Optional. Amount of time in seconds the poll will be active after creation */ |
73 | - public null|int $open_period = null; |
|
73 | + public null | int $open_period = null; |
|
74 | 74 | |
75 | 75 | /** Optional. Point in time (Unix timestamp) when the poll will be automatically closed */ |
76 | - public null|int $close_date = null; |
|
76 | + public null | int $close_date = null; |
|
77 | 77 | |
78 | 78 | |
79 | - public function __construct(stdClass|null $object = null) { |
|
79 | + public function __construct(stdClass | null $object = null) { |
|
80 | 80 | if ($object != null) { |
81 | 81 | parent::__construct($object, self::subs); |
82 | 82 | } |
@@ -54,114 +54,114 @@ |
||
54 | 54 | public int $update_id; |
55 | 55 | |
56 | 56 | /** Optional. New incoming message of any kind - text, photo, sticker, etc. */ |
57 | - public null|message $message = null; |
|
57 | + public null | message $message = null; |
|
58 | 58 | |
59 | 59 | /** |
60 | 60 | * Optional. New version of a message that is known to the bot and was edited. This update may at times be |
61 | 61 | * triggered by changes to message fields that are either unavailable or not actively used by your bot. |
62 | 62 | */ |
63 | - public null|message $edited_message = null; |
|
63 | + public null | message $edited_message = null; |
|
64 | 64 | |
65 | 65 | /** Optional. New incoming channel post of any kind - text, photo, sticker, etc. */ |
66 | - public null|message $channel_post = null; |
|
66 | + public null | message $channel_post = null; |
|
67 | 67 | |
68 | 68 | /** |
69 | 69 | * Optional. New version of a channel post that is known to the bot and was edited. This update may at times be |
70 | 70 | * triggered by changes to message fields that are either unavailable or not actively used by your bot. |
71 | 71 | */ |
72 | - public null|message $edited_channel_post = null; |
|
72 | + public null | message $edited_channel_post = null; |
|
73 | 73 | |
74 | 74 | /** |
75 | 75 | * Optional. The bot was connected to or disconnected from a business account, or a user edited an existing |
76 | 76 | * connection with the bot |
77 | 77 | */ |
78 | - public null|businessConnection $business_connection = null; |
|
78 | + public null | businessConnection $business_connection = null; |
|
79 | 79 | |
80 | 80 | /** Optional. New message from a connected business account */ |
81 | - public null|message $business_message = null; |
|
81 | + public null | message $business_message = null; |
|
82 | 82 | |
83 | 83 | /** Optional. New version of a message from a connected business account */ |
84 | - public null|message $edited_business_message = null; |
|
84 | + public null | message $edited_business_message = null; |
|
85 | 85 | |
86 | 86 | /** Optional. Messages were deleted from a connected business account */ |
87 | - public null|businessMessagesDeleted $deleted_business_messages = null; |
|
87 | + public null | businessMessagesDeleted $deleted_business_messages = null; |
|
88 | 88 | |
89 | 89 | /** |
90 | 90 | * Optional. A reaction to a message was changed by a user. The bot must be an administrator in the chat and must |
91 | 91 | * explicitly specify "message_reaction" in the list of allowed_updates to receive these updates. The update |
92 | 92 | * isn't received for reactions set by bots. |
93 | 93 | */ |
94 | - public null|messageReactionUpdated $message_reaction = null; |
|
94 | + public null | messageReactionUpdated $message_reaction = null; |
|
95 | 95 | |
96 | 96 | /** |
97 | 97 | * Optional. Reactions to a message with anonymous reactions were changed. The bot must be an administrator in |
98 | 98 | * the chat and must explicitly specify "message_reaction_count" in the list of allowed_updates to receive these |
99 | 99 | * updates. The updates are grouped and can be sent with delay up to a few minutes. |
100 | 100 | */ |
101 | - public null|messageReactionCountUpdated $message_reaction_count = null; |
|
101 | + public null | messageReactionCountUpdated $message_reaction_count = null; |
|
102 | 102 | |
103 | 103 | /** Optional. New incoming inline query */ |
104 | - public null|inlineQuery $inline_query = null; |
|
104 | + public null | inlineQuery $inline_query = null; |
|
105 | 105 | |
106 | 106 | /** |
107 | 107 | * Optional. The result of an inline query that was chosen by a user and sent to their chat partner. Please see |
108 | 108 | * our documentation on the feedback collecting for details on how to enable these updates for your bot. |
109 | 109 | */ |
110 | - public null|chosenInlineResult $chosen_inline_result = null; |
|
110 | + public null | chosenInlineResult $chosen_inline_result = null; |
|
111 | 111 | |
112 | 112 | /** Optional. New incoming callback query */ |
113 | - public null|callbackQuery $callback_query = null; |
|
113 | + public null | callbackQuery $callback_query = null; |
|
114 | 114 | |
115 | 115 | /** Optional. New incoming shipping query. Only for invoices with flexible price */ |
116 | - public null|shippingQuery $shipping_query = null; |
|
116 | + public null | shippingQuery $shipping_query = null; |
|
117 | 117 | |
118 | 118 | /** Optional. New incoming pre-checkout query. Contains full information about checkout */ |
119 | - public null|preCheckoutQuery $pre_checkout_query = null; |
|
119 | + public null | preCheckoutQuery $pre_checkout_query = null; |
|
120 | 120 | |
121 | 121 | /** |
122 | 122 | * Optional. New poll state. Bots receive only updates about manually stopped polls and polls, which are sent by |
123 | 123 | * the bot |
124 | 124 | */ |
125 | - public null|poll $poll = null; |
|
125 | + public null | poll $poll = null; |
|
126 | 126 | |
127 | 127 | /** |
128 | 128 | * Optional. A user changed their answer in a non-anonymous poll. Bots receive new votes only in polls that were |
129 | 129 | * sent by the bot itself. |
130 | 130 | */ |
131 | - public null|pollAnswer $poll_answer = null; |
|
131 | + public null | pollAnswer $poll_answer = null; |
|
132 | 132 | |
133 | 133 | /** |
134 | 134 | * Optional. The bot's chat member status was updated in a chat. For private chats, this update is received only |
135 | 135 | * when the bot is blocked or unblocked by the user. |
136 | 136 | */ |
137 | - public null|chatMemberUpdated $my_chat_member = null; |
|
137 | + public null | chatMemberUpdated $my_chat_member = null; |
|
138 | 138 | |
139 | 139 | /** |
140 | 140 | * Optional. A chat member's status was updated in a chat. The bot must be an administrator in the chat and must |
141 | 141 | * explicitly specify "chat_member" in the list of allowed_updates to receive these updates. |
142 | 142 | */ |
143 | - public null|chatMemberUpdated $chat_member = null; |
|
143 | + public null | chatMemberUpdated $chat_member = null; |
|
144 | 144 | |
145 | 145 | /** |
146 | 146 | * Optional. A request to join the chat has been sent. The bot must have the can_invite_users administrator right |
147 | 147 | * in the chat to receive these updates. |
148 | 148 | */ |
149 | - public null|chatJoinRequest $chat_join_request = null; |
|
149 | + public null | chatJoinRequest $chat_join_request = null; |
|
150 | 150 | |
151 | 151 | /** |
152 | 152 | * Optional. A chat boost was added or changed. The bot must be an administrator in the chat to receive these |
153 | 153 | * updates. |
154 | 154 | */ |
155 | - public null|chatBoostUpdated $chat_boost = null; |
|
155 | + public null | chatBoostUpdated $chat_boost = null; |
|
156 | 156 | |
157 | 157 | /** |
158 | 158 | * Optional. A boost was removed from a chat. The bot must be an administrator in the chat to receive these |
159 | 159 | * updates. |
160 | 160 | */ |
161 | - public null|chatBoostRemoved $removed_chat_boost = null; |
|
161 | + public null | chatBoostRemoved $removed_chat_boost = null; |
|
162 | 162 | |
163 | 163 | |
164 | - public function __construct(stdClass|null $object = null) { |
|
164 | + public function __construct(stdClass | null $object = null) { |
|
165 | 165 | if ($object != null) { |
166 | 166 | parent::__construct($object, self::subs); |
167 | 167 | } |
@@ -84,13 +84,13 @@ discard block |
||
84 | 84 | public int $message_id; |
85 | 85 | |
86 | 86 | /** Optional. Unique identifier of a message thread to which the message belongs; for supergroups only */ |
87 | - public null|int $message_thread_id = null; |
|
87 | + public null | int $message_thread_id = null; |
|
88 | 88 | |
89 | 89 | /** |
90 | 90 | * Optional. Sender of the message; empty for messages sent to channels. For backward compatibility, the field |
91 | 91 | * contains a fake sender user in non-channel chats, if the message was sent on behalf of a chat. |
92 | 92 | */ |
93 | - public null|user $from = null; |
|
93 | + public null | user $from = null; |
|
94 | 94 | |
95 | 95 | /** |
96 | 96 | * Optional. Sender of the message, sent on behalf of a chat. For example, the channel itself for channel posts, |
@@ -98,16 +98,16 @@ discard block |
||
98 | 98 | * automatically forwarded to the discussion group. For backward compatibility, the field from contains a fake |
99 | 99 | * sender user in non-channel chats, if the message was sent on behalf of a chat. |
100 | 100 | */ |
101 | - public null|chat $sender_chat = null; |
|
101 | + public null | chat $sender_chat = null; |
|
102 | 102 | |
103 | 103 | /** Optional. If the sender of the message boosted the chat, the number of boosts added by the user */ |
104 | - public null|int $sender_boost_count = null; |
|
104 | + public null | int $sender_boost_count = null; |
|
105 | 105 | |
106 | 106 | /** |
107 | 107 | * Optional. The bot that actually sent the message on behalf of the business account. Available only for |
108 | 108 | * outgoing messages sent on behalf of the connected business account. |
109 | 109 | */ |
110 | - public null|user $sender_business_bot = null; |
|
110 | + public null | user $sender_business_bot = null; |
|
111 | 111 | |
112 | 112 | /** Date the message was sent in Unix time. It is always a positive number, representing a valid date. */ |
113 | 113 | public int $date; |
@@ -117,7 +117,7 @@ discard block |
||
117 | 117 | * message belongs to a chat of the corresponding business account that is independent from any potential bot |
118 | 118 | * chat which might share the same identifier. |
119 | 119 | */ |
120 | - public null|string $business_connection_id = null; |
|
120 | + public null | string $business_connection_id = null; |
|
121 | 121 | |
122 | 122 | /** Chat the message belongs to */ |
123 | 123 | public chat $chat; |
@@ -127,7 +127,7 @@ discard block |
||
127 | 127 | * |
128 | 128 | * @deprecated used forward_origin instead |
129 | 129 | */ |
130 | - public null|user $forward_from = null; |
|
130 | + public null | user $forward_from = null; |
|
131 | 131 | |
132 | 132 | /** |
133 | 133 | * Optional. For messages forwarded from channels or from anonymous administrators, information about the |
@@ -135,14 +135,14 @@ discard block |
||
135 | 135 | * |
136 | 136 | * @deprecated used forward_origin instead |
137 | 137 | */ |
138 | - public null|chat $forward_from_chat = null; |
|
138 | + public null | chat $forward_from_chat = null; |
|
139 | 139 | |
140 | 140 | /** |
141 | 141 | * Optional. For messages forwarded from channels, identifier of the original message in the channel |
142 | 142 | * |
143 | 143 | * @deprecated used forward_origin instead |
144 | 144 | */ |
145 | - public null|int $forward_from_message_id = null; |
|
145 | + public null | int $forward_from_message_id = null; |
|
146 | 146 | |
147 | 147 | /** |
148 | 148 | * Optional. For forwarded messages that were originally sent in channels or by an anonymous chat administrator, |
@@ -150,7 +150,7 @@ discard block |
||
150 | 150 | * |
151 | 151 | * @deprecated used forward_origin instead |
152 | 152 | */ |
153 | - public null|string $forward_signature = null; |
|
153 | + public null | string $forward_signature = null; |
|
154 | 154 | |
155 | 155 | /** |
156 | 156 | * Optional. Sender's name for messages forwarded from users who disallow adding a link to their account in |
@@ -158,206 +158,206 @@ discard block |
||
158 | 158 | * |
159 | 159 | * @deprecated used forward_origin instead |
160 | 160 | */ |
161 | - public null|string $forward_sender_name = null; |
|
161 | + public null | string $forward_sender_name = null; |
|
162 | 162 | |
163 | 163 | /** |
164 | 164 | * Optional. For forwarded messages, date the original message was sent in Unix time |
165 | 165 | * @deprecated used forward_origin instead |
166 | 166 | */ |
167 | - public null|int $forward_date = null; |
|
167 | + public null | int $forward_date = null; |
|
168 | 168 | |
169 | 169 | /** Optional. Information about the original message for forwarded messages */ |
170 | - public null|messageOrigin $forward_origin = null; |
|
170 | + public null | messageOrigin $forward_origin = null; |
|
171 | 171 | |
172 | 172 | /** Optional. True, if the message is sent to a forum topic */ |
173 | - public null|bool $is_topic_message = null; |
|
173 | + public null | bool $is_topic_message = null; |
|
174 | 174 | |
175 | 175 | /** |
176 | 176 | * Optional. True, if the message is a channel post that was automatically forwarded to the connected discussion |
177 | 177 | * group |
178 | 178 | */ |
179 | - public null|bool $is_automatic_forward = null; |
|
179 | + public null | bool $is_automatic_forward = null; |
|
180 | 180 | |
181 | 181 | /** |
182 | 182 | * Optional. For replies in the same chat and message thread, the original message. Note that the Message object |
183 | 183 | * in this field will not contain further reply_to_message fields even if it itself is a reply. |
184 | 184 | */ |
185 | - public null|message $reply_to_message = null; |
|
185 | + public null | message $reply_to_message = null; |
|
186 | 186 | |
187 | 187 | /** |
188 | 188 | * Optional. Information about the message that is being replied to, which may come from another chat or forum |
189 | 189 | * topic |
190 | 190 | */ |
191 | - public null|externalReplyInfo $external_reply = null; |
|
191 | + public null | externalReplyInfo $external_reply = null; |
|
192 | 192 | |
193 | 193 | /** Optional. For replies that quote part of the original message, the quoted part of the message */ |
194 | - public null|textQuote $quote = null; |
|
194 | + public null | textQuote $quote = null; |
|
195 | 195 | |
196 | 196 | /** Optional. For replies to a story, the original story */ |
197 | - public null|story $reply_to_story = null; |
|
197 | + public null | story $reply_to_story = null; |
|
198 | 198 | |
199 | 199 | /** Optional. Bot through which the message was sent */ |
200 | - public null|user $via_bot = null; |
|
200 | + public null | user $via_bot = null; |
|
201 | 201 | |
202 | 202 | /** Optional. Date the message was last edited in Unix time */ |
203 | - public null|int $edit_date = null; |
|
203 | + public null | int $edit_date = null; |
|
204 | 204 | |
205 | 205 | /** Optional. True, if the message can't be forwarded */ |
206 | - public null|bool $has_protected_content = null; |
|
206 | + public null | bool $has_protected_content = null; |
|
207 | 207 | |
208 | 208 | /** |
209 | 209 | * Optional. True, if the message was sent by an implicit action, for example, as an away or a greeting business |
210 | 210 | * message, or as a scheduled message |
211 | 211 | */ |
212 | - public null|bool $is_from_offline = null; |
|
212 | + public null | bool $is_from_offline = null; |
|
213 | 213 | |
214 | 214 | /** Optional. The unique identifier of a media message group this message belongs to */ |
215 | - public null|string $media_group_id = null; |
|
215 | + public null | string $media_group_id = null; |
|
216 | 216 | |
217 | 217 | /** |
218 | 218 | * Optional. Signature of the post author for messages in channels, or the custom title of an anonymous group |
219 | 219 | * administrator |
220 | 220 | */ |
221 | - public null|string $author_signature = null; |
|
221 | + public null | string $author_signature = null; |
|
222 | 222 | |
223 | 223 | /** Optional. For text messages, the actual UTF-8 text of the message */ |
224 | - public null|string $text = null; |
|
224 | + public null | string $text = null; |
|
225 | 225 | |
226 | 226 | /** Optional. If user message was a command , this parameter will be the command */ |
227 | - public string|null $command = null; |
|
227 | + public string | null $command = null; |
|
228 | 228 | |
229 | 229 | /** Optional. If user message was a command , this parameter will be the command username(if exist) */ |
230 | - public string|null $command_username = null; |
|
230 | + public string | null $command_username = null; |
|
231 | 231 | |
232 | 232 | /** Optional. If user message was a command , this parameter will be the command payload(if exist) */ |
233 | - public string|null $command_payload = null; |
|
233 | + public string | null $command_payload = null; |
|
234 | 234 | |
235 | 235 | /** |
236 | 236 | * Optional. For text messages, special entities like usernames, URLs, bot commands, etc. that appear in the text |
237 | 237 | * @var messageEntity[] |
238 | 238 | */ |
239 | - public null|array $entities = null; |
|
239 | + public null | array $entities = null; |
|
240 | 240 | |
241 | 241 | /** |
242 | 242 | * Optional. Options used for link preview generation for the message, if it is a text message and link preview |
243 | 243 | * options were changed |
244 | 244 | */ |
245 | - public null|linkPreviewOptions $link_preview_options = null; |
|
245 | + public null | linkPreviewOptions $link_preview_options = null; |
|
246 | 246 | |
247 | 247 | /** Optional. Unique identifier of the message effect added to the message */ |
248 | - public null|string $effect_id = null; |
|
248 | + public null | string $effect_id = null; |
|
249 | 249 | |
250 | 250 | /** |
251 | 251 | * Optional. Message is an animation, information about the animation. For backward compatibility, when this |
252 | 252 | * field is set, the document field will also be set |
253 | 253 | */ |
254 | - public null|animation $animation = null; |
|
254 | + public null | animation $animation = null; |
|
255 | 255 | |
256 | 256 | /** Optional. Message is an audio file, information about the file */ |
257 | - public null|audio $audio = null; |
|
257 | + public null | audio $audio = null; |
|
258 | 258 | |
259 | 259 | /** Optional. Message is a general file, information about the file */ |
260 | - public null|document $document = null; |
|
260 | + public null | document $document = null; |
|
261 | 261 | |
262 | 262 | /** |
263 | 263 | * Optional. Message is a photo, available sizes of the photo |
264 | 264 | * @var photoSize[] |
265 | 265 | */ |
266 | - public null|array $photo = null; |
|
266 | + public null | array $photo = null; |
|
267 | 267 | |
268 | 268 | /** Optional. Message is a sticker, information about the sticker */ |
269 | - public null|sticker $sticker = null; |
|
269 | + public null | sticker $sticker = null; |
|
270 | 270 | |
271 | 271 | /** Optional. Message is a forwarded story */ |
272 | - public null|story $story = null; |
|
272 | + public null | story $story = null; |
|
273 | 273 | |
274 | 274 | /** Optional. Message is a video, information about the video */ |
275 | - public null|video $video = null; |
|
275 | + public null | video $video = null; |
|
276 | 276 | |
277 | 277 | /** Optional. Message is a video note, information about the video message */ |
278 | - public null|videoNote $video_note = null; |
|
278 | + public null | videoNote $video_note = null; |
|
279 | 279 | |
280 | 280 | /** Optional. Message is a voice message, information about the file */ |
281 | - public null|voice $voice = null; |
|
281 | + public null | voice $voice = null; |
|
282 | 282 | |
283 | 283 | /** Optional. Caption for the animation, audio, document, photo, video or voice */ |
284 | - public null|string $caption = null; |
|
284 | + public null | string $caption = null; |
|
285 | 285 | |
286 | 286 | /** |
287 | 287 | * Optional. For messages with a caption, special entities like usernames, URLs, bot commands, etc. that appear |
288 | 288 | * in the caption |
289 | 289 | * @var messageEntity[] |
290 | 290 | */ |
291 | - public null|array $caption_entities = null; |
|
291 | + public null | array $caption_entities = null; |
|
292 | 292 | |
293 | 293 | /** Optional. True, if the caption must be shown above the message media */ |
294 | - public null|bool $show_caption_above_media = null; |
|
294 | + public null | bool $show_caption_above_media = null; |
|
295 | 295 | |
296 | 296 | /** Optional. True, if the message media is covered by a spoiler animation */ |
297 | - public null|bool $has_media_spoiler = null; |
|
297 | + public null | bool $has_media_spoiler = null; |
|
298 | 298 | |
299 | 299 | /** Optional. Message is a shared contact, information about the contact */ |
300 | - public null|contact $contact = null; |
|
300 | + public null | contact $contact = null; |
|
301 | 301 | |
302 | 302 | /** Optional. Message is a dice with random value */ |
303 | - public null|dice $dice = null; |
|
303 | + public null | dice $dice = null; |
|
304 | 304 | |
305 | 305 | /** Optional. Message is a game, information about the game. More about games » */ |
306 | - public null|game $game = null; |
|
306 | + public null | game $game = null; |
|
307 | 307 | |
308 | 308 | /** Optional. Message is a native poll, information about the poll */ |
309 | - public null|poll $poll = null; |
|
309 | + public null | poll $poll = null; |
|
310 | 310 | |
311 | 311 | /** |
312 | 312 | * Optional. Message is a venue, information about the venue. For backward compatibility, when this field is set, |
313 | 313 | * the location field will also be set |
314 | 314 | */ |
315 | - public null|venue $venue = null; |
|
315 | + public null | venue $venue = null; |
|
316 | 316 | |
317 | 317 | /** Optional. Message is a shared location, information about the location */ |
318 | - public null|location $location = null; |
|
318 | + public null | location $location = null; |
|
319 | 319 | |
320 | 320 | /** |
321 | 321 | * Optional. New members that were added to the group or supergroup and information about them (the bot itself |
322 | 322 | * may be one of these members) |
323 | 323 | * @var user[] |
324 | 324 | */ |
325 | - public null|array $new_chat_members = null; |
|
325 | + public null | array $new_chat_members = null; |
|
326 | 326 | |
327 | 327 | /** Optional. A member was removed from the group, information about them (this member may be the bot itself) */ |
328 | - public null|user $left_chat_member = null; |
|
328 | + public null | user $left_chat_member = null; |
|
329 | 329 | |
330 | 330 | /** Optional. A chat title was changed to this value */ |
331 | - public null|string $new_chat_title = null; |
|
331 | + public null | string $new_chat_title = null; |
|
332 | 332 | |
333 | 333 | /** |
334 | 334 | * Optional. A chat photo was change to this value |
335 | 335 | * @var photoSize[] |
336 | 336 | */ |
337 | - public null|array $new_chat_photo = null; |
|
337 | + public null | array $new_chat_photo = null; |
|
338 | 338 | |
339 | 339 | /** Optional. Service message: the chat photo was deleted */ |
340 | - public null|bool $delete_chat_photo = null; |
|
340 | + public null | bool $delete_chat_photo = null; |
|
341 | 341 | |
342 | 342 | /** Optional. Service message: the group has been created */ |
343 | - public null|bool $group_chat_created = null; |
|
343 | + public null | bool $group_chat_created = null; |
|
344 | 344 | |
345 | 345 | /** |
346 | 346 | * Optional. Service message: the supergroup has been created. This field can't be received in a message coming |
347 | 347 | * through updates, because bot can't be a member of a supergroup when it is created. It can only be found in |
348 | 348 | * reply_to_message if someone replies to a very first message in a directly created supergroup. |
349 | 349 | */ |
350 | - public null|bool $supergroup_chat_created = null; |
|
350 | + public null | bool $supergroup_chat_created = null; |
|
351 | 351 | |
352 | 352 | /** |
353 | 353 | * Optional. Service message: the channel has been created. This field can't be received in a message coming |
354 | 354 | * through updates, because bot can't be a member of a channel when it is created. It can only be found in |
355 | 355 | * reply_to_message if someone replies to a very first message in a channel. |
356 | 356 | */ |
357 | - public null|bool $channel_chat_created = null; |
|
357 | + public null | bool $channel_chat_created = null; |
|
358 | 358 | |
359 | 359 | /** Optional. Service message: auto-delete timer settings changed in the chat */ |
360 | - public null|messageAutoDeleteTimerChanged $message_auto_delete_timer_changed = null; |
|
360 | + public null | messageAutoDeleteTimerChanged $message_auto_delete_timer_changed = null; |
|
361 | 361 | |
362 | 362 | /** |
363 | 363 | * Optional. The group has been migrated to a supergroup with the specified identifier. This number may have more |
@@ -365,7 +365,7 @@ discard block |
||
365 | 365 | * But it has at most 52 significant bits, so a signed 64-bit integer or double-precision float type are safe for |
366 | 366 | * storing this identifier. |
367 | 367 | */ |
368 | - public null|int $migrate_to_chat_id = null; |
|
368 | + public null | int $migrate_to_chat_id = null; |
|
369 | 369 | |
370 | 370 | /** |
371 | 371 | * Optional. The supergroup has been migrated from a group with the specified identifier. This number may have |
@@ -373,25 +373,25 @@ discard block |
||
373 | 373 | * interpreting it. But it has at most 52 significant bits, so a signed 64-bit integer or double-precision float |
374 | 374 | * type are safe for storing this identifier. |
375 | 375 | */ |
376 | - public null|int $migrate_from_chat_id = null; |
|
376 | + public null | int $migrate_from_chat_id = null; |
|
377 | 377 | |
378 | 378 | /** |
379 | 379 | * Optional. Specified message was pinned. Note that the Message object in this field will not contain further |
380 | 380 | * reply_to_message fields even if it itself is a reply. |
381 | 381 | */ |
382 | - public null|maybeInaccessibleMessage $pinned_message = null; |
|
382 | + public null | maybeInaccessibleMessage $pinned_message = null; |
|
383 | 383 | |
384 | 384 | /** Optional. Message is an invoice for a payment, information about the invoice. More about payments » */ |
385 | - public null|invoice $invoice = null; |
|
385 | + public null | invoice $invoice = null; |
|
386 | 386 | |
387 | 387 | /** |
388 | 388 | * Optional. Message is a service message about a successful payment, information about the payment. More about |
389 | 389 | * payments » |
390 | 390 | */ |
391 | - public null|successfulPayment $successful_payment = null; |
|
391 | + public null | successfulPayment $successful_payment = null; |
|
392 | 392 | |
393 | 393 | /** Optional. Service message: users were shared with the bot */ |
394 | - public null|usersShared $users_shared = null; |
|
394 | + public null | usersShared $users_shared = null; |
|
395 | 395 | |
396 | 396 | /** |
397 | 397 | * Optional. Service message: a user was shared with the bot |
@@ -400,86 +400,86 @@ discard block |
||
400 | 400 | * |
401 | 401 | * @deprecated use users_shared instead |
402 | 402 | */ |
403 | - public null|userShared $user_shared = null; |
|
403 | + public null | userShared $user_shared = null; |
|
404 | 404 | |
405 | 405 | /** Optional. Service message: a chat was shared with the bot */ |
406 | - public null|chatShared $chat_shared = null; |
|
406 | + public null | chatShared $chat_shared = null; |
|
407 | 407 | |
408 | 408 | /** Optional. The domain name of the website on which the user has logged in. More about Telegram Login » */ |
409 | - public null|string $connected_website = null; |
|
409 | + public null | string $connected_website = null; |
|
410 | 410 | |
411 | 411 | /** |
412 | 412 | * Optional. Service message: the user allowed the bot to write messages after adding it to the attachment or |
413 | 413 | * side menu, launching a Web App from a link, or accepting an explicit request from a Web App sent by the method |
414 | 414 | * requestWriteAccess |
415 | 415 | */ |
416 | - public null|writeAccessAllowed $write_access_allowed = null; |
|
416 | + public null | writeAccessAllowed $write_access_allowed = null; |
|
417 | 417 | |
418 | 418 | /** Optional. Telegram Passport data */ |
419 | - public null|passportData $passport_data = null; |
|
419 | + public null | passportData $passport_data = null; |
|
420 | 420 | |
421 | 421 | /** |
422 | 422 | * Optional. Service message. A user in the chat triggered another user's proximity alert while sharing Live |
423 | 423 | * Location. |
424 | 424 | */ |
425 | - public null|proximityAlertTriggered $proximity_alert_triggered = null; |
|
425 | + public null | proximityAlertTriggered $proximity_alert_triggered = null; |
|
426 | 426 | |
427 | 427 | /** Optional. Service message: user boosted the chat */ |
428 | - public null|chatBoostAdded $boost_added = null; |
|
428 | + public null | chatBoostAdded $boost_added = null; |
|
429 | 429 | |
430 | 430 | /** Optional. Service message: chat background set */ |
431 | - public null|chatBackground $chat_background_set = null; |
|
431 | + public null | chatBackground $chat_background_set = null; |
|
432 | 432 | |
433 | 433 | /** Optional. Service message: forum topic created */ |
434 | - public null|forumTopicCreated $forum_topic_created = null; |
|
434 | + public null | forumTopicCreated $forum_topic_created = null; |
|
435 | 435 | |
436 | 436 | /** Optional. Service message: forum topic edited */ |
437 | - public null|forumTopicEdited $forum_topic_edited = null; |
|
437 | + public null | forumTopicEdited $forum_topic_edited = null; |
|
438 | 438 | |
439 | 439 | /** Optional. Service message: forum topic closed */ |
440 | - public null|forumTopicClosed $forum_topic_closed = null; |
|
440 | + public null | forumTopicClosed $forum_topic_closed = null; |
|
441 | 441 | |
442 | 442 | /** Optional. Service message: forum topic reopened */ |
443 | - public null|forumTopicReopened $forum_topic_reopened = null; |
|
443 | + public null | forumTopicReopened $forum_topic_reopened = null; |
|
444 | 444 | |
445 | 445 | /** Optional. Service message: the 'General' forum topic hidden */ |
446 | - public null|generalForumTopicHidden $general_forum_topic_hidden = null; |
|
446 | + public null | generalForumTopicHidden $general_forum_topic_hidden = null; |
|
447 | 447 | |
448 | 448 | /** Optional. Service message: the 'General' forum topic unhidden */ |
449 | - public null|generalForumTopicUnhidden $general_forum_topic_unhidden = null; |
|
449 | + public null | generalForumTopicUnhidden $general_forum_topic_unhidden = null; |
|
450 | 450 | |
451 | 451 | /** Optional. Service message: a scheduled giveaway was created */ |
452 | - public null|giveawayCreated $giveaway_created = null; |
|
452 | + public null | giveawayCreated $giveaway_created = null; |
|
453 | 453 | |
454 | 454 | /** Optional. The message is a scheduled giveaway message */ |
455 | - public null|giveaway $giveaway = null; |
|
455 | + public null | giveaway $giveaway = null; |
|
456 | 456 | |
457 | 457 | /** Optional. A giveaway with public winners was completed */ |
458 | - public null|giveawayWinners $giveaway_winners = null; |
|
458 | + public null | giveawayWinners $giveaway_winners = null; |
|
459 | 459 | |
460 | 460 | /** Optional. Service message: a giveaway without public winners was completed */ |
461 | - public null|giveawayCompleted $giveaway_completed = null; |
|
461 | + public null | giveawayCompleted $giveaway_completed = null; |
|
462 | 462 | |
463 | 463 | /** Optional. Service message: video chat scheduled */ |
464 | - public null|videoChatScheduled $video_chat_scheduled = null; |
|
464 | + public null | videoChatScheduled $video_chat_scheduled = null; |
|
465 | 465 | |
466 | 466 | /** Optional. Service message: video chat started */ |
467 | - public null|videoChatStarted $video_chat_started = null; |
|
467 | + public null | videoChatStarted $video_chat_started = null; |
|
468 | 468 | |
469 | 469 | /** Optional. Service message: video chat ended */ |
470 | - public null|videoChatEnded $video_chat_ended = null; |
|
470 | + public null | videoChatEnded $video_chat_ended = null; |
|
471 | 471 | |
472 | 472 | /** Optional. Service message: new participants invited to a video chat */ |
473 | - public null|videoChatParticipantsInvited $video_chat_participants_invited = null; |
|
473 | + public null | videoChatParticipantsInvited $video_chat_participants_invited = null; |
|
474 | 474 | |
475 | 475 | /** Optional. Service message: data sent by a Web App */ |
476 | - public null|webAppData $web_app_data = null; |
|
476 | + public null | webAppData $web_app_data = null; |
|
477 | 477 | |
478 | 478 | /** Optional. Inline keyboard attached to the message. login_url buttons are represented as ordinary url buttons. */ |
479 | - public null|inlineKeyboardMarkup $reply_markup = null; |
|
479 | + public null | inlineKeyboardMarkup $reply_markup = null; |
|
480 | 480 | |
481 | 481 | |
482 | - public function __construct(stdClass|null $object = null) { |
|
482 | + public function __construct(stdClass | null $object = null) { |
|
483 | 483 | if ($object != null) { |
484 | 484 | parent::__construct($object, self::subs); |
485 | 485 | |
@@ -491,7 +491,7 @@ discard block |
||
491 | 491 | * |
492 | 492 | * @return bool |
493 | 493 | */ |
494 | - public function isCommand (): bool { |
|
494 | + public function isCommand(): bool { |
|
495 | 495 | return !empty($this->command); |
496 | 496 | } |
497 | 497 | |
@@ -500,7 +500,7 @@ discard block |
||
500 | 500 | * |
501 | 501 | * @return bool |
502 | 502 | */ |
503 | - public function isForwarded (): bool { |
|
503 | + public function isForwarded(): bool { |
|
504 | 504 | return $this->forward_origin !== null; |
505 | 505 | } |
506 | 506 | |
@@ -509,7 +509,7 @@ discard block |
||
509 | 509 | * |
510 | 510 | * @return bool |
511 | 511 | */ |
512 | - public function isReplied (): bool { |
|
512 | + public function isReplied(): bool { |
|
513 | 513 | return !empty($this->reply_to_message); |
514 | 514 | } |
515 | 515 | |
@@ -520,7 +520,7 @@ discard block |
||
520 | 520 | * |
521 | 521 | * @return bool |
522 | 522 | */ |
523 | - public function isAdmin (): bool { |
|
523 | + public function isAdmin(): bool { |
|
524 | 524 | return $this->chat->getMember($this->from->id)->status === chatMemberStatus::ADMINISTRATOR; |
525 | 525 | } |
526 | 526 | |
@@ -531,7 +531,7 @@ discard block |
||
531 | 531 | * |
532 | 532 | * @return bool |
533 | 533 | */ |
534 | - public function isOwner (): bool { |
|
534 | + public function isOwner(): bool { |
|
535 | 535 | return $this->chat->getMember($this->from->id)->status === chatMemberStatus::CREATOR; |
536 | 536 | } |
537 | 537 | |
@@ -544,7 +544,7 @@ discard block |
||
544 | 544 | * |
545 | 545 | * @return responseError|bool |
546 | 546 | */ |
547 | - public function banMember(bool $answer = null): responseError|bool { |
|
547 | + public function banMember(bool $answer = null): responseError | bool { |
|
548 | 548 | if ($this->chat->isPrivate()) { |
549 | 549 | return false; |
550 | 550 | } |
@@ -560,7 +560,7 @@ discard block |
||
560 | 560 | * |
561 | 561 | * @return responseError|bool |
562 | 562 | */ |
563 | - public function kickMember(bool $answer = null): responseError|bool { |
|
563 | + public function kickMember(bool $answer = null): responseError | bool { |
|
564 | 564 | if ($this->chat->isPrivate()) { |
565 | 565 | return false; |
566 | 566 | } |
@@ -574,8 +574,8 @@ discard block |
||
574 | 574 | * |
575 | 575 | * @return responseError|bool |
576 | 576 | */ |
577 | - public function delete (bool $answer = null): responseError|bool { |
|
578 | - return telegram::deleteMessage($this->chat->id,$this->id, answer: $answer); |
|
577 | + public function delete(bool $answer = null): responseError | bool { |
|
578 | + return telegram::deleteMessage($this->chat->id, $this->id, answer: $answer); |
|
579 | 579 | } |
580 | 580 | |
581 | 581 | /** |
@@ -585,8 +585,8 @@ discard block |
||
585 | 585 | * |
586 | 586 | * @return responseError|bool |
587 | 587 | */ |
588 | - public function pinChatMessage (bool $answer = null): responseError|bool { |
|
589 | - return telegram::deleteMessage($this->chat->id,$this->id, answer: $answer); |
|
588 | + public function pinChatMessage(bool $answer = null): responseError | bool { |
|
589 | + return telegram::deleteMessage($this->chat->id, $this->id, answer: $answer); |
|
590 | 590 | } |
591 | 591 | |
592 | 592 | /** |
@@ -597,8 +597,8 @@ discard block |
||
597 | 597 | * |
598 | 598 | * @return message|responseError|bool |
599 | 599 | */ |
600 | - public function editText (string $text, bool $answer = null): message|responseError|bool { |
|
601 | - return telegram::editMessageText($text, $this->chat->id, $this->message_id, answer: $answer); |
|
600 | + public function editText(string $text, bool $answer = null): message | responseError | bool { |
|
601 | + return telegram::editMessageText($text, $this->chat->id, $this->message_id, answer: $answer); |
|
602 | 602 | } |
603 | 603 | |
604 | 604 | /** |
@@ -609,7 +609,7 @@ discard block |
||
609 | 609 | * |
610 | 610 | * @return messageId|responseError |
611 | 611 | */ |
612 | - public function copy (int|string $chat_id, bool $answer = null): messageId|responseError { |
|
612 | + public function copy(int | string $chat_id, bool $answer = null): messageId | responseError { |
|
613 | 613 | return telegram::copyMessage($chat_id, answer: $answer); |
614 | 614 | } |
615 | 615 | |
@@ -621,7 +621,7 @@ discard block |
||
621 | 621 | * |
622 | 622 | * @return message|responseError |
623 | 623 | */ |
624 | - public function forward (int|string $chat_id, bool $answer = null): message|responseError { |
|
624 | + public function forward(int | string $chat_id, bool $answer = null): message | responseError { |
|
625 | 625 | return telegram::forwardMessage($chat_id, answer: $answer); |
626 | 626 | } |
627 | 627 | } |