Explorar el Código

exception in prompts

pull/6/head
pb hace 3 años
padre
commit
7ffb88dd35
Se han modificado 1 ficheros con 8 adiciones y 3 borrados
  1. 8
    3
      cliverse.js

+ 8
- 3
cliverse.js Ver fichero

@@ -107,9 +107,14 @@ var cli = {
const clii = readline.createInterface({ input: process.stdin, output: process.stdout });
return new Promise((resolve, reject)=>{
clii.question(q, (answer)=>{
clii.close();
console.log("resolve is being called");
resolve(answer)
try {
clii.close();
console.log("readline.createInterface closed");
resolve(answer)
}
catch(e) {
reject(e)
}
})
})
}

Cargando…
Cancelar
Guardar