Wait for ConversationController
load in receipt and sync jobs
This commit is contained in:
parent
29c3b8af89
commit
ed96e603ab
3 changed files with 32 additions and 0 deletions
|
@ -102,6 +102,8 @@ export async function runReadOrViewSyncJob({
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
await window.ConversationController.load();
|
||||||
|
|
||||||
const ourConversation =
|
const ourConversation =
|
||||||
window.ConversationController.getOurConversationOrThrow();
|
window.ConversationController.getOurConversationOrThrow();
|
||||||
const sendOptions = await getSendOptions(ourConversation.attributes, {
|
const sendOptions = await getSendOptions(ourConversation.attributes, {
|
||||||
|
|
|
@ -7851,6 +7851,20 @@
|
||||||
"reasonCategory": "usageTrusted",
|
"reasonCategory": "usageTrusted",
|
||||||
"updated": "2021-10-22T00:52:39.251Z"
|
"updated": "2021-10-22T00:52:39.251Z"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"rule": "jQuery-load(",
|
||||||
|
"path": "ts/jobs/helpers/readAndViewSyncHelpers.js",
|
||||||
|
"line": " await window.ConversationController.load();",
|
||||||
|
"reasonCategory": "falseMatch",
|
||||||
|
"updated": "2021-12-15T19:58:28.089Z"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"rule": "jQuery-load(",
|
||||||
|
"path": "ts/jobs/helpers/readAndViewSyncHelpers.ts",
|
||||||
|
"line": " await window.ConversationController.load();",
|
||||||
|
"reasonCategory": "falseMatch",
|
||||||
|
"updated": "2021-12-15T19:58:28.089Z"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"rule": "jQuery-load(",
|
"rule": "jQuery-load(",
|
||||||
"path": "ts/jobs/normalMessageSendJobQueue.js",
|
"path": "ts/jobs/normalMessageSendJobQueue.js",
|
||||||
|
@ -8152,6 +8166,20 @@
|
||||||
"updated": "2021-08-18T18:22:55.307Z",
|
"updated": "2021-08-18T18:22:55.307Z",
|
||||||
"reasonDetail": "Legacy code"
|
"reasonDetail": "Legacy code"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"rule": "jQuery-load(",
|
||||||
|
"path": "ts/util/sendReceipts.js",
|
||||||
|
"line": " await window.ConversationController.load();",
|
||||||
|
"reasonCategory": "falseMatch",
|
||||||
|
"updated": "2021-12-15T19:58:28.089Z"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"rule": "jQuery-load(",
|
||||||
|
"path": "ts/util/sendReceipts.ts",
|
||||||
|
"line": " await window.ConversationController.load();",
|
||||||
|
"reasonCategory": "falseMatch",
|
||||||
|
"updated": "2021-12-15T19:58:28.089Z"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"rule": "jQuery-$(",
|
"rule": "jQuery-$(",
|
||||||
"path": "ts/util/setupI18n.js",
|
"path": "ts/util/setupI18n.js",
|
||||||
|
|
|
@ -79,6 +79,8 @@ export async function sendReceipts({
|
||||||
new Map()
|
new Map()
|
||||||
);
|
);
|
||||||
|
|
||||||
|
await window.ConversationController.load();
|
||||||
|
|
||||||
await Promise.all(
|
await Promise.all(
|
||||||
map(receiptsBySenderId, async ([senderId, receiptsForSender]) => {
|
map(receiptsBySenderId, async ([senderId, receiptsForSender]) => {
|
||||||
const sender = window.ConversationController.get(senderId);
|
const sender = window.ConversationController.get(senderId);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue