Skip to content

Commit

Permalink
GH-4352: Fixed the logic when guessing the cause of the LS failure.
Browse files Browse the repository at this point in the history
Closes: #4352

Signed-off-by: Akos Kitta <[email protected]>
  • Loading branch information
Akos Kitta authored and kittaakos committed Feb 15, 2019
1 parent 4b0b09d commit 5967a99
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ export abstract class BaseLanguageServerContribution implements LanguageServerCo
rawProcess.onError((error: ProcessErrorEvent) => {
this.onDidFailSpawnProcess(error);
if (error.code === 'ENOENT') {
const guess = command.split('\S').shift();
const guess = command.split(/\s+/).shift();
if (guess) {
reject(new Error(`Failed to spawn ${guess}\nPerhaps it is not on the PATH.`));
return;
Expand Down

0 comments on commit 5967a99

Please sign in to comment.