diff options
author | Veetaha <[email protected]> | 2020-02-09 20:00:33 +0000 |
---|---|---|
committer | Veetaha <[email protected]> | 2020-02-09 20:00:33 +0000 |
commit | 5d39f6d3b2fe9fcb08a9e9d4bad7edc42b3c9ea2 (patch) | |
tree | 5e858a7f26267853e18e3bcb8916b639f8b57519 /editors/code | |
parent | fa7b91a2f7732d78f1b7af52fc26bcf57f1c0044 (diff) |
vscode: add on-success logic to dns resolution sanity check
Diffstat (limited to 'editors/code')
-rw-r--r-- | editors/code/src/installation/language_server.ts | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/editors/code/src/installation/language_server.ts b/editors/code/src/installation/language_server.ts index 9fb1ce42e..fd8b2caac 100644 --- a/editors/code/src/installation/language_server.ts +++ b/editors/code/src/installation/language_server.ts | |||
@@ -105,10 +105,13 @@ export async function ensureLanguageServerBinary( | |||
105 | `GitHub repository: ${err.message}` | 105 | `GitHub repository: ${err.message}` |
106 | ); | 106 | ); |
107 | 107 | ||
108 | dns.resolve('www.google.com').catch(err => { | 108 | dns.resolve('www.google.com').then( |
109 | console.error("DNS resolution failed, there might be an issue with Internet availability"); | 109 | addrs => console.log("DNS resolution was successful", addrs), |
110 | console.error(err); | 110 | err => { |
111 | }); | 111 | console.error("DNS resolution failed, there might be an issue with Internet availability"); |
112 | console.error(err); | ||
113 | } | ||
114 | ); | ||
112 | 115 | ||
113 | return null; | 116 | return null; |
114 | } | 117 | } |