git rid of uncaught promise error
This commit is contained in:
parent
a599d44c10
commit
534e82ffaf
@ -90,12 +90,13 @@ async function showMessageWithTimeout(message: string, timeout: number): Promise
|
||||
|
||||
|
||||
// show a message on the status bar until the promise is resolved
|
||||
async function showPendingStatusBar(message: string, resolve: Promise<any>): Promise<void> {
|
||||
async function showPendingStatusBar(message: string, operation: Promise<any>): Promise<void> {
|
||||
void vscode.window.withProgress(
|
||||
{
|
||||
location: vscode.ProgressLocation.Window,
|
||||
title: message,
|
||||
}, () => { return resolve; });
|
||||
}, () => operation ).then((aok) => {}, (err) => {});
|
||||
// we already resolve the operation elsewhere
|
||||
}
|
||||
|
||||
|
||||
@ -201,7 +202,6 @@ export function activate(context: vscode.ExtensionContext) {
|
||||
req_str = '/completion';
|
||||
request.prompt = doc_before;
|
||||
}
|
||||
console.log(fim);
|
||||
|
||||
let data: llamaData;
|
||||
// try to send the request to the running server
|
||||
|
Loading…
Reference in New Issue
Block a user