diff --git a/compiler/scripts/release/prompt-for-otp.js b/compiler/scripts/release/prompt-for-otp.js index 3cb1e419c784e..9797cbb663f58 100644 --- a/compiler/scripts/release/prompt-for-otp.js +++ b/compiler/scripts/release/prompt-for-otp.js @@ -11,14 +11,13 @@ const prompt = require('prompt-promise'); const run = async () => { while (true) { const otp = await prompt('NPM 2-factor auth code: '); - prompt.done(); if (otp) { + prompt.done(); return otp; } else { - console.error('\nTwo-factor auth is required to publish.'); - // (Ask again.) + console.error('\nTwo-factor authentication code is required to publish.'); } } }; -module.exports = run; +module.exports = run; \ No newline at end of file