mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-03 07:04:49 +00:00
vscode: add on-success logic to dns resolution sanity check
This commit is contained in:
parent
fa7b91a2f7
commit
5d39f6d3b2
1 changed files with 7 additions and 4 deletions
|
@ -105,10 +105,13 @@ export async function ensureLanguageServerBinary(
|
||||||
`GitHub repository: ${err.message}`
|
`GitHub repository: ${err.message}`
|
||||||
);
|
);
|
||||||
|
|
||||||
dns.resolve('www.google.com').catch(err => {
|
dns.resolve('www.google.com').then(
|
||||||
|
addrs => console.log("DNS resolution was successful", addrs),
|
||||||
|
err => {
|
||||||
console.error("DNS resolution failed, there might be an issue with Internet availability");
|
console.error("DNS resolution failed, there might be an issue with Internet availability");
|
||||||
console.error(err);
|
console.error(err);
|
||||||
});
|
}
|
||||||
|
);
|
||||||
|
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue