1
0
mirror of https://github.com/danog/MadelineProto.git synced 2024-11-26 17:24:40 +01:00

Improve editHide

This commit is contained in:
Daniil Gentili 2024-08-23 13:31:54 +02:00
parent 001bce6c52
commit 7a14e12e4c
2 changed files with 11 additions and 19 deletions

View File

@ -165,6 +165,13 @@
<code><![CDATA[$this->broadcasts[$id]]]></code>
<code><![CDATA[$this->broadcasts[$id]]]></code>
</DocblockTypeContradiction>
<MixedArrayAccess>
<code><![CDATA[$message['media']['_']]]></code>
</MixedArrayAccess>
<MixedAssignment>
<code><![CDATA[$message]]></code>
<code><![CDATA[$message['media']]]></code>
</MixedAssignment>
<RedundantConditionGivenDocblockType>
<code><![CDATA[$this->broadcasts[$id]?->cancel()]]></code>
<code><![CDATA[$this->broadcasts[$id]?->getProgress()]]></code>
@ -1387,6 +1394,7 @@
<code><![CDATA[$r['reaction']['document_id']]]></code>
<code><![CDATA[$r['reaction']['emoticon']]]></code>
<code><![CDATA[$rawMessage['edit_date']]]></code>
<code><![CDATA[$rawMessage['edit_hide']]]></code>
<code><![CDATA[$rawMessage['entities']]]></code>
<code><![CDATA[$rawMessage['forwards']]]></code>
<code><![CDATA[$rawMessage['from_scheduled']]]></code>
@ -1418,6 +1426,7 @@
<code><![CDATA[$result]]></code>
<code><![CDATA[$result]]></code>
<code><![CDATA[$this->editDate]]></code>
<code><![CDATA[$this->editHide]]></code>
<code><![CDATA[$this->forwards]]></code>
<code><![CDATA[$this->fromScheduled]]></code>
<code><![CDATA[$this->groupedId]]></code>
@ -7410,9 +7419,6 @@
<MissingReturnType>
<code><![CDATA[getVar]]></code>
</MissingReturnType>
<MixedArgument>
<code><![CDATA[$hash]]></code>
</MixedArgument>
<MixedArrayAccess>
<code><![CDATA[$val['@type']]]></code>
</MixedArrayAccess>
@ -7420,11 +7426,6 @@
<code><![CDATA[$val['_']]]></code>
</MixedArrayAssignment>
<MixedAssignment>
<code><![CDATA[$hash]]></code>
<code><![CDATA[$hash]]></code>
<code><![CDATA[$hash]]></code>
<code><![CDATA[$hash]]></code>
<code><![CDATA[$long]]></code>
<code><![CDATA[$parent]]></code>
<code><![CDATA[$parent]]></code>
<code><![CDATA[$val['_']]]></code>
@ -7433,15 +7434,6 @@
<code><![CDATA[getAttribute]]></code>
<code><![CDATA[getAttribute]]></code>
</MixedMethodCall>
<MixedOperand>
<code><![CDATA[$hash]]></code>
<code><![CDATA[$hash]]></code>
<code><![CDATA[$hash]]></code>
<code><![CDATA[$hash]]></code>
<code><![CDATA[$hash]]></code>
<code><![CDATA[$hash]]></code>
<code><![CDATA[$hash >> 21]]></code>
</MixedOperand>
<MixedReturnStatement>
<code><![CDATA[unpack('d', Magic::$BIG_ENDIAN ? strrev($value) : $value)[1]]]></code>
<code><![CDATA[unpack('l', Magic::$BIG_ENDIAN ? strrev($value) : $value)[1]]]></code>

View File

@ -92,7 +92,7 @@ abstract class Message extends AbstractMessage
* Indicates if the post has a hidden edit, which is an edit that does not modify the actual message content.
* Used to signify non-content related updates such as reactions.
*/
public readonly ?bool $editHide;
public readonly bool $editHide;
/** Inline or reply keyboard. */
public readonly InlineKeyboard|ReplyKeyboard|null $keyboard;
@ -153,7 +153,7 @@ abstract class Message extends AbstractMessage
$this->signature = $rawMessage['post_author'] ?? null;
$this->groupedId = $rawMessage['grouped_id'] ?? null;
$this->editDate = $rawMessage['edit_date'] ?? null;
$this->editHide = $rawMessage['edit_hide'] ?? null;
$this->editHide = $rawMessage['edit_hide'] ?? false;
$this->message = $rawMessage['message'];
$this->fromScheduled = $rawMessage['from_scheduled'] ?? false;