@mtcute/core 0.19.1 → 0.19.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/highlevel/types/messages/dialog.cjs +3 -1
- package/highlevel/types/messages/dialog.js +3 -1
- package/highlevel/types/premium/stars-gift.cjs +1 -1
- package/highlevel/types/premium/stars-gift.d.cts +1 -1
- package/highlevel/types/premium/stars-gift.d.ts +1 -1
- package/highlevel/types/premium/stars-gift.js +1 -1
- package/network/network-manager.cjs +1 -1
- package/network/network-manager.js +1 -1
- package/package.json +3 -3
|
@@ -158,7 +158,9 @@ class Dialog {
|
|
|
158
158
|
get lastMessage() {
|
|
159
159
|
const cid = this.peer.id;
|
|
160
160
|
if (this._messages.has(cid)) {
|
|
161
|
-
|
|
161
|
+
const msg = this._messages.get(cid);
|
|
162
|
+
if (msg._ === "messageEmpty") return null;
|
|
163
|
+
return new message.Message(msg, this._peers);
|
|
162
164
|
}
|
|
163
165
|
return null;
|
|
164
166
|
}
|
|
@@ -151,7 +151,9 @@ class Dialog {
|
|
|
151
151
|
get lastMessage() {
|
|
152
152
|
const cid = this.peer.id;
|
|
153
153
|
if (this._messages.has(cid)) {
|
|
154
|
-
|
|
154
|
+
const msg = this._messages.get(cid);
|
|
155
|
+
if (msg._ === "messageEmpty") return null;
|
|
156
|
+
return new Message$2(msg, this._peers);
|
|
155
157
|
}
|
|
156
158
|
return null;
|
|
157
159
|
}
|
|
@@ -30,7 +30,7 @@ class StarGift {
|
|
|
30
30
|
return this.raw.limited;
|
|
31
31
|
}
|
|
32
32
|
/** Whether this gift is a unique gift */
|
|
33
|
-
isUnique =
|
|
33
|
+
isUnique = false;
|
|
34
34
|
/** Additional information for sold-out gifts */
|
|
35
35
|
get soldOutInfo() {
|
|
36
36
|
if (this.raw.firstSaleDate == null || this.raw.lastSaleDate == null) {
|
|
@@ -17,7 +17,7 @@ export declare class StarGift {
|
|
|
17
17
|
/** Whether this gift has limited availability */
|
|
18
18
|
get isLimited(): boolean;
|
|
19
19
|
/** Whether this gift is a unique gift */
|
|
20
|
-
readonly isUnique:
|
|
20
|
+
readonly isUnique: false;
|
|
21
21
|
/** Additional information for sold-out gifts */
|
|
22
22
|
get soldOutInfo(): {
|
|
23
23
|
/** Date when the first gift was bought */
|
|
@@ -17,7 +17,7 @@ export declare class StarGift {
|
|
|
17
17
|
/** Whether this gift has limited availability */
|
|
18
18
|
get isLimited(): boolean;
|
|
19
19
|
/** Whether this gift is a unique gift */
|
|
20
|
-
readonly isUnique:
|
|
20
|
+
readonly isUnique: false;
|
|
21
21
|
/** Additional information for sold-out gifts */
|
|
22
22
|
get soldOutInfo(): {
|
|
23
23
|
/** Date when the first gift was bought */
|
|
@@ -23,7 +23,7 @@ class StarGift {
|
|
|
23
23
|
return this.raw.limited;
|
|
24
24
|
}
|
|
25
25
|
/** Whether this gift is a unique gift */
|
|
26
|
-
isUnique =
|
|
26
|
+
isUnique = false;
|
|
27
27
|
/** Additional information for sold-out gifts */
|
|
28
28
|
get soldOutInfo() {
|
|
29
29
|
if (this.raw.firstSaleDate == null || this.raw.lastSaleDate == null) {
|
package/package.json
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mtcute/core",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.19.
|
|
4
|
+
"version": "0.19.3",
|
|
5
5
|
"description": "Type-safe library for MTProto (Telegram API)",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"scripts": {},
|
|
8
8
|
"dependencies": {
|
|
9
|
-
"@fuman/io": "0.0.
|
|
10
|
-
"@fuman/net": "0.0.
|
|
9
|
+
"@fuman/io": "0.0.8",
|
|
10
|
+
"@fuman/net": "0.0.9",
|
|
11
11
|
"@fuman/utils": "0.0.4",
|
|
12
12
|
"@mtcute/file-id": "^0.19.0",
|
|
13
13
|
"@mtcute/tl": "^196.0.0",
|