瀏覽代碼

exception in prompts

master
pb 3 年之前
父節點
當前提交
7ffb88dd35
共有 1 個檔案被更改,包括 8 行新增3 行删除
  1. 8
    3
      cliverse.js

+ 8
- 3
cliverse.js 查看文件

@@ -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)
}
})
})
}

Loading…
取消
儲存