fix(core): handle no dialog in conversation
This commit is contained in:
parent
dcd757ec5e
commit
974739f2d5
1 changed files with 2 additions and 1 deletions
|
@ -171,7 +171,8 @@ export class Conversation {
|
|||
this._chatId = getMarkedPeerId(this._inputPeer)
|
||||
|
||||
const [dialog] = await getPeerDialogs(this.client, this._inputPeer)
|
||||
const lastMessage = dialog.lastMessage
|
||||
|
||||
const lastMessage = dialog?.lastMessage
|
||||
|
||||
if (lastMessage) {
|
||||
this._lastMessage = this._lastReceivedMessage = lastMessage.id
|
||||
|
|
Loading…
Reference in a new issue