From 2c01662c7f1475575eb008d456c84a6f3a011cd9 Mon Sep 17 00:00:00 2001 From: Martin Vanbrabant Date: Tue, 11 Jul 2023 10:39:25 +0200 Subject: [PATCH] rough workaround for https://github.com/SolidLabResearch/Bashlib/issues/55 --- src/authentication/authenticate.ts | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/src/authentication/authenticate.ts b/src/authentication/authenticate.ts index 8cf8a3a..4305748 100644 --- a/src/authentication/authenticate.ts +++ b/src/authentication/authenticate.ts @@ -82,19 +82,20 @@ export default async function authenticate(options: ILoginOptions): Promise<{ fe async function queryUserAuthentication() { // Ask the user if they want to authenticate. If not, use cross-fetch, else give them a prompt to provide an idp - console.log(`Do you want to authenticate the current request? [Y, n] `); - let userWantsToAuthenticate : boolean = await new Promise((resolve, reject) => { - process.stdin.setRawMode(true); - process.stdin.resume(); - process.stdin.on('data', (chk) => { - if (chk.toString('utf8') === "n") { - resolve(false); - } else { - resolve(true); - } - }); - }); - return userWantsToAuthenticate +// console.log(`Do you want to authenticate the current request? [Y, n] `); +// let userWantsToAuthenticate : boolean = await new Promise((resolve, reject) => { +// process.stdin.setRawMode(true); +// process.stdin.resume(); +// process.stdin.on('data', (chk) => { +// if (chk.toString('utf8') === "n") { +// resolve(false); +// } else { +// resolve(true); +// } +// }); +// }); +// return userWantsToAuthenticate + return false }