Skip to content

Commit

Permalink
fix: use stdout instead of console
Browse files Browse the repository at this point in the history
  • Loading branch information
Cori Hudson committed Sep 22, 2022
1 parent bc151d5 commit f298a58
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
3 changes: 1 addition & 2 deletions lib/transifex.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,7 @@ const txPull = async function (project, resource, locale, mode = 'default') {
buffer = await download(url);
return JSON.parse(buffer.toString());
} catch (e) {
// eslint-disable-next-line no-console
console.error(`got ${e.message}, retrying after ${i + 1} failed attempt(s)`);
process.stdout.write(`got ${e.message}, retrying after ${i + 1} failed attempt(s)\n`);
}
}
throw Error('failed to pull after 5 retries');
Expand Down
3 changes: 1 addition & 2 deletions scripts/tx-pull-www.js
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,7 @@ const getLocaleData = async function (item) {
file: fileName
};
} catch (e) {
// eslint-disable-next-line no-console
console.error(`got ${e.message}, retrying after ${i + 1} attempts`);
process.stdout.write(`got ${e.message}, retrying after ${i + 1} attempt(s)\n`);
}
}
throw Error('failed to pull translations after 5 retries');
Expand Down

0 comments on commit f298a58

Please sign in to comment.