fix conversation result usage in loadEntireConversation

In loadEntireConversation, json was an array of [result, request], now it only takes result into account
This commit is contained in:
Clément de La Bourdonnaye
2020-06-14 21:02:52 +02:00
committed by GitHub
parent a109e321cb
commit bc2889272f

View File

@@ -102,7 +102,7 @@ module.exports = {
const loadMessage = () => {
return this.loadConversation(jid, chunkSize, offsetID, mostRecentFirst)
.then (json => {
.then (([json]) => {
if (json[2]) {
// callback with most recent message first (descending order of date)
let lastMessage
@@ -201,4 +201,4 @@ module.exports = {
const json = ["query", "inviteCode", jid]
return this.query (json).then (([json, _]) => json.code)
}
}
}