Add missing awaits in SQL logging
This commit is contained in:
parent
25458be515
commit
cb75e8b5f7
1 changed files with 5 additions and 5 deletions
|
@ -1729,7 +1729,7 @@ async function initialize({
|
||||||
globalInstance = db;
|
globalInstance = db;
|
||||||
|
|
||||||
// test database
|
// test database
|
||||||
getMessageCount();
|
await getMessageCount();
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.log('Database startup error:', error.stack);
|
console.log('Database startup error:', error.stack);
|
||||||
if (db) {
|
if (db) {
|
||||||
|
@ -1778,7 +1778,7 @@ async function initializeRenderer({
|
||||||
globalInstanceRenderer = promisified;
|
globalInstanceRenderer = promisified;
|
||||||
|
|
||||||
// test database
|
// test database
|
||||||
getMessageCount();
|
await getMessageCount();
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
window.log.error('Database startup error:', error.stack);
|
window.log.error('Database startup error:', error.stack);
|
||||||
throw error;
|
throw error;
|
||||||
|
@ -4300,7 +4300,7 @@ async function removeKnownAttachments(
|
||||||
);
|
);
|
||||||
const chunkSize = 50;
|
const chunkSize = 50;
|
||||||
|
|
||||||
const total = getMessageCount();
|
const total = await getMessageCount();
|
||||||
console.log(
|
console.log(
|
||||||
`removeKnownAttachments: About to iterate through ${total} messages`
|
`removeKnownAttachments: About to iterate through ${total} messages`
|
||||||
);
|
);
|
||||||
|
@ -4350,7 +4350,7 @@ async function removeKnownAttachments(
|
||||||
// value is still a string but it's smaller than every other string.
|
// value is still a string but it's smaller than every other string.
|
||||||
id = 0;
|
id = 0;
|
||||||
|
|
||||||
const conversationTotal = getConversationCount();
|
const conversationTotal = await getConversationCount();
|
||||||
console.log(
|
console.log(
|
||||||
`removeKnownAttachments: About to iterate through ${conversationTotal} conversations`
|
`removeKnownAttachments: About to iterate through ${conversationTotal} conversations`
|
||||||
);
|
);
|
||||||
|
@ -4453,7 +4453,7 @@ async function removeKnownDraftAttachments(
|
||||||
);
|
);
|
||||||
const chunkSize = 50;
|
const chunkSize = 50;
|
||||||
|
|
||||||
const total = getConversationCount();
|
const total = await getConversationCount();
|
||||||
console.log(
|
console.log(
|
||||||
`removeKnownDraftAttachments: About to iterate through ${total} conversations`
|
`removeKnownDraftAttachments: About to iterate through ${total} conversations`
|
||||||
);
|
);
|
||||||
|
|
Loading…
Add table
Reference in a new issue