mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-26 16:46:12 +01:00
fix: inReplyTo bug, #12834
This commit is contained in:
@@ -488,9 +488,7 @@ Mocks.notes.private = async ({ messageObj }) => {
|
|||||||
// Get immediately preceding message
|
// Get immediately preceding message
|
||||||
const index = await db.sortedSetRank(`chat:room:${messageObj.roomId}:mids`, messageObj.mid);
|
const index = await db.sortedSetRank(`chat:room:${messageObj.roomId}:mids`, messageObj.mid);
|
||||||
const previousMid = await db.getSortedSetRange(`chat:room:${messageObj.roomId}:mids`, index - 1, index - 1);
|
const previousMid = await db.getSortedSetRange(`chat:room:${messageObj.roomId}:mids`, index - 1, index - 1);
|
||||||
inReplyTo = utils.isNumber(previousMid) ?
|
inReplyTo = utils.isNumber(previousMid) ? `${nconf.get('url')}/message/${previousMid}` : previousMid;
|
||||||
`${nconf.get('url')}/message/${previousMid}` :
|
|
||||||
messageObj.toMid;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
const object = {
|
const object = {
|
||||||
|
|||||||
Reference in New Issue
Block a user