You've already forked joplin
mirror of
https://github.com/laurent22/joplin.git
synced 2025-07-13 00:10:37 +02:00
Tools: Add eslint rule prefer-await-to-then
This commit is contained in:
@ -36,6 +36,7 @@ async function createClients() {
|
||||
const client = createClient(clientId);
|
||||
promises.push(fs.remove(client.profileDir));
|
||||
promises.push(
|
||||
// eslint-disable-next-line promise/prefer-await-to-then -- Old code before rule was applied
|
||||
execCommand(client, 'config sync.target 2').then(() => {
|
||||
return execCommand(client, `config sync.2.path ${syncDir}`);
|
||||
})
|
||||
@ -2324,10 +2325,12 @@ async function main() {
|
||||
clients[clientId].activeCommandCount++;
|
||||
|
||||
execRandomCommand(clients[clientId])
|
||||
// eslint-disable-next-line promise/prefer-await-to-then -- Old code before rule was applied
|
||||
.catch(error => {
|
||||
logger.info(`Client ${clientId}:`);
|
||||
logger.error(error);
|
||||
})
|
||||
// eslint-disable-next-line promise/prefer-await-to-then -- Old code before rule was applied
|
||||
.then(r => {
|
||||
if (r) {
|
||||
logger.info(`Client ${clientId}:\n${r.trim()}`);
|
||||
|
Reference in New Issue
Block a user