Fix error on syncing channel with no new messages

This commit is contained in:
Andrew Ferrazzutti 2022-04-23 13:58:18 -04:00
parent 13cb5f87ff
commit 143e1f23f8
1 changed files with 1 additions and 1 deletions

View File

@ -690,7 +690,7 @@ export default class PeerClient {
const talkChannel = await this.#getUserChannel(req.mxid, req.channel_props)
const res = await talkChannel.getChatListFrom(req.sync_from)
if (!res.success) return res
if (!res.success || !res.length) return res
while (true) {
const nextRes = await talkChannel.getChatListFrom(