fix: fix kv connection error in extensions

This commit is contained in:
Ash Keel 2023-05-03 17:22:36 +02:00
parent 2cf63534e5
commit bc6c76c581
No known key found for this signature in database
GPG Key ID: BAD8D93E7314ED3E
2 changed files with 5 additions and 6 deletions

View File

@ -1 +1 @@
293b48c0e126b4f88d9b5ba934df5908
b9df5eb6f4841737d2fcd1301b0eb45f

View File

@ -59,11 +59,10 @@ onmessage = async (ev: MessageEvent<ExtensionHostCommand>) => {
switch (cmd.kind) {
case 'arguments': {
// Create Kilovolt instance
kv = new Kilovolt(
cmd.dependencies.kilovolt.address,
cmd.dependencies.kilovolt.password,
);
await kv.wait();
kv = new Kilovolt(cmd.dependencies.kilovolt.address, {
password: cmd.dependencies.kilovolt.password,
});
await kv.connect();
try {
// Transpile TS into JS